(8.2ms) CREATE TABLE "schema_migrations" ("version" character varying(255) NOT NULL)   (3.4ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version") ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations" Migrating to CreateUsers (20150907004705)  (0.3ms) BEGIN  (14.5ms) CREATE TABLE "users" ("id" serial primary key, "email" character varying(255), "created_at" timestamp, "updated_at" timestamp)  SQL (0.4ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20150907004705"]]  (5.9ms) COMMIT Migrating to CreateNotifyUserNotifications (20150907004707)  (5.6ms) BEGIN  (11.1ms) CREATE TABLE "notify_user_notifications" ("id" serial primary key, "type" character varying(255), "target_id" integer, "target_type" character varying(255), "params" json, "state" character varying(255), "sent_time" timestamp, "group_id" integer, "parent_id" integer, "created_at" timestamp, "updated_at" timestamp)   (1.1ms) CREATE INDEX "index_notify_user_notifications_on_group_id" ON "notify_user_notifications" ("group_id")  (0.9ms) CREATE INDEX "index_notify_user_notifications_on_parent_id" ON "notify_user_notifications" ("parent_id")  (1.2ms) CREATE INDEX "index_notify_user_notifications_on_target_id" ON "notify_user_notifications" ("target_id") SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20150907004707"]]  (0.8ms) COMMIT Migrating to CreateNotifyUserUnsubscribes (20150907004708)  (0.3ms) BEGIN  (5.4ms) CREATE TABLE "notify_user_unsubscribes" ("id" serial primary key, "type" character varying(255), "target_id" integer, "target_type" character varying(255), "group_id" integer, "created_at" timestamp, "updated_at" timestamp)  (0.9ms) CREATE INDEX "index_notify_user_unsubscribes_on_group_id" ON "notify_user_unsubscribes" ("group_id")  (0.9ms) CREATE INDEX "index_notify_user_unsubscribes_on_target_id" ON "notify_user_unsubscribes" ("target_id") SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20150907004708"]]  (0.5ms) COMMIT Migrating to CreateNotifyUserUserHashes (20150907004709)  (0.2ms) BEGIN  (15.3ms) CREATE TABLE "notify_user_user_hashes" ("id" serial primary key, "type" character varying(255), "target_id" integer, "target_type" character varying(255), "token" character varying(255), "active" boolean DEFAULT 't', "created_at" timestamp, "updated_at" timestamp) SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20150907004709"]]  (6.4ms) COMMIT ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (117.6ms) DROP DATABASE IF EXISTS "notify_user_test"  (242.3ms) CREATE DATABASE "notify_user_test" ENCODING = 'unicode'  (117.0ms) DROP DATABASE IF EXISTS "notify_user_test"  (250.4ms) CREATE DATABASE "notify_user_test" ENCODING = 'unicode' SQL (0.4ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (5.8ms) CREATE TABLE "notify_user_notifications" ("id" serial primary key, "type" character varying(255), "target_id" integer, "target_type" character varying(255), "params" json, "state" character varying(255), "sent_time" timestamp, "group_id" integer, "parent_id" integer, "created_at" timestamp, "updated_at" timestamp)  (1.1ms) CREATE INDEX "index_notify_user_notifications_on_group_id" ON "notify_user_notifications" USING btree ("group_id")  (1.1ms) CREATE INDEX "index_notify_user_notifications_on_parent_id" ON "notify_user_notifications" USING btree ("parent_id")  (1.2ms) CREATE INDEX "index_notify_user_notifications_on_target_id" ON "notify_user_notifications" USING btree ("target_id")  (3.6ms) CREATE TABLE "notify_user_unsubscribes" ("id" serial primary key, "type" character varying(255), "target_id" integer, "target_type" character varying(255), "group_id" integer, "created_at" timestamp, "updated_at" timestamp)  (1.1ms) CREATE INDEX "index_notify_user_unsubscribes_on_group_id" ON "notify_user_unsubscribes" USING btree ("group_id")  (1.0ms) CREATE INDEX "index_notify_user_unsubscribes_on_target_id" ON "notify_user_unsubscribes" USING btree ("target_id")  (3.5ms) CREATE TABLE "notify_user_user_hashes" ("id" serial primary key, "type" character varying(255), "target_id" integer, "target_type" character varying(255), "token" character varying(255), "active" boolean DEFAULT 't', "created_at" timestamp, "updated_at" timestamp)   (2.5ms) CREATE TABLE "users" ("id" serial primary key, "email" character varying(255), "created_at" timestamp, "updated_at" timestamp)  (1.0ms) CREATE TABLE "schema_migrations" ("version" character varying(255) NOT NULL)   (1.1ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.4ms) SELECT version FROM "schema_migrations"  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20150907004709')  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20150907004705')  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20150907004707')  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20150907004708')  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.598370"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.598370"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.609760"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.609760"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.8ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.644313"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 2], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.644313"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.652060"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.652060"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 3 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.658432"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 3], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.658432"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.665166"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.665166"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 4 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.671466"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 4], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.671466"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 4 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.675771"], ["parent_id", 1], ["state", "pending"], ["target_id", 4], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.675771"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.682040"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.682040"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 5 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.687908"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 5], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.687908"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 5 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.693013"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 5], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.693013"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 5 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.697014"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 5], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.697014"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.704012"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.704012"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 6 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.717383"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 6], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.717383"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 6 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.722164"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 6], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.722164"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 6 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.728556"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 6], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.728556"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.739859"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.739859"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 7 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.747075"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 7], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.747075"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 7 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.750512"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 7], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.750512"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 7 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.754091"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 7], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.754091"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.760048"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.760048"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 8 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.766992"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 8], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.766992"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 8 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.770573"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 8], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.770573"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 8 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.774274"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 8], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.774274"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.779934"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.779934"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.790353"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.790353"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.4ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.800029"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.800029"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 11 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.805823"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 11], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.805823"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.811422"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.811422"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 12 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.816979"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 12], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.816979"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.822737"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.822737"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 13 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.828834"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 13], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.828834"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 13 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.838876"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.838876"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 14 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.847729"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 14], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.847729"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 14 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.854398"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.854398"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 15 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.860799"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 15], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.860799"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.866416"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.866416"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 16 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.9ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.872403"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 16], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.872403"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (1.2ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 16) LIMIT 1 SQL (0.5ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:47:15.891398"], ["target_id", 16], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.891398"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:15.898506"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:15.898506"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 17 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:15.904608"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 17], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.904608"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (1.2ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 17 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'T_d9Rpw9jkKJ63EBHrkyRQRuLs1Izh3EfvCXDAAvRrNg' LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:15.915459"], ["target_id", 17], ["target_type", "User"], ["token", "T_d9Rpw9jkKJ63EBHrkyRQRuLs1Izh3EfvCXDAAvRrNg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:15.915459"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.3ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (3.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 268.9ms Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.7ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.4ms Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.5ms Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.231591"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.231591"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 18 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.235355"], ["state", "pending"], ["target_id", 18], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.235355"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.240990"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.240990"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 19 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.245843"], ["state", "pending"], ["target_id", 19], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.245843"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.251348"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.251348"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 20 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.254750"], ["state", "pending"], ["target_id", 20], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.254750"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.259192"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.259192"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 21 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.262624"], ["state", "pending"], ["target_id", 21], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.262624"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.267364"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.267364"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 22 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.270766"], ["state", "pending"], ["target_id", 22], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.270766"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 22 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.276731"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.276731"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 23 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.280707"], ["state", "pending"], ["target_id", 23], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.280707"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.286283"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.286283"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 24 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.289934"], ["state", "pending"], ["target_id", 24], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.289934"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.295756"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.295756"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 25 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.299118"], ["state", "pending"], ["target_id", 25], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.299118"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 25 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 31 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:47:16.302077"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.6ms) BEGIN  (0.8ms) SAVEPOINT active_record_1 SQL (1.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.315478"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.315478"]]  (0.7ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 26 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.328225"], ["state", "pending"], ["target_id", 26], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.328225"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 26 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 32 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:47:16.332218"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.337218"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.337218"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 27 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.342077"], ["state", "pending"], ["target_id", 27], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.342077"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 27 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 33 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:47:16.345871"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.350938"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.350938"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 28 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.354217"], ["state", "pending"], ["target_id", 28], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.354217"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 28 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 34 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:47:16.357834"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.363674"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.363674"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 29 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.367040"], ["state", "pending"], ["target_id", 29], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.367040"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 29 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.373137"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.373137"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 30 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.376890"], ["state", "pending"], ["target_id", 30], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.376890"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 30 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 30 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 36 [["state", "sent"], ["updated_at", "2015-09-07 00:47:16.383240"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 30 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 36 [["sent_time", "2015-09-07 00:47:16.384568"], ["updated_at", "2015-09-07 00:47:16.386081"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.390553"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.390553"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 31 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.394808"], ["state", "pending"], ["target_id", 31], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.394808"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 31 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 31 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 37)  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 31 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 37 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:16.402218"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 37]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 31]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 31 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 31]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 31 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 37 [["sent_time", "2015-09-07 00:47:16.412762"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:16.415762"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 31 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 37]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 31]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 31 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 31 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 31 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'TIj2Mv3Z5LqNx5yXOFC0lgxbcToTLzbVWl8jF8noUkgA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.428008"], ["target_id", 31], ["target_type", "User"], ["token", "TIj2Mv3Z5LqNx5yXOFC0lgxbcToTLzbVWl8jF8noUkgA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.428008"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 8.0ms Sent mail to user@example.com (6.4ms) Date: Mon, 07 Sep 2015 10:47:16 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecde946a6e2_e3b43feb594601fc7559d@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.442211"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.442211"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 32 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.446017"], ["state", "pending_as_aggregation_parent"], ["target_id", 32], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.446017"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 32 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.449532"], ["state", "pending"], ["target_id", 32], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.449532"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 32 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 32 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 39)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.456580"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.456580"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 33 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.460160"], ["state", "pending"], ["target_id", 33], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.460160"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 33 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 33 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 40 [["state", "sent"], ["updated_at", "2015-09-07 00:47:16.464896"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 33 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 40 [["sent_time", "2015-09-07 00:47:16.466121"], ["updated_at", "2015-09-07 00:47:16.467646"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 40]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 33]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 33 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 33 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.3ms) NotifyUser::UserHash Load (1.0ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 33 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.3ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'qRjsDgfa5eWYaCennSg3kAQvIafbHrJ0kwOcmp6C0WLw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.480073"], ["target_id", 33], ["target_type", "User"], ["token", "qRjsDgfa5eWYaCennSg3kAQvIafbHrJ0kwOcmp6C0WLw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.480073"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 7.6ms Sent mail to user@example.com (1.9ms) Date: Mon, 07 Sep 2015 10:47:16 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecde9476268_e3b43feb594601fc7564c@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.488148"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.488148"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 34 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.491460"], ["state", "pending"], ["target_id", 34], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.491460"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 34 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 41 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-07 00:47:16.494857"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.499289"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.499289"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 35 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.502768"], ["state", "pending"], ["target_id", 35], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.502768"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 35) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:47:16.506055"], ["target_id", 35], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:47:16.506055"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 42]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 35]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 35 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 35 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.515429"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.515429"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 36 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.8ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.519377"], ["state", "pending"], ["target_id", 36], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.519377"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 43]] User Load (0.6ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 36]]  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 36 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 36 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.531670"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.531670"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 37 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.534842"], ["state", "pending"], ["target_id", 37], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.534842"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 37 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 37 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 44 [["state", "sent"], ["updated_at", "2015-09-07 00:47:16.539496"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 37 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 44 [["sent_time", "2015-09-07 00:47:16.541545"], ["updated_at", "2015-09-07 00:47:16.543218"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 44]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 37]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 37 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 37 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 37 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '1If0moz2ZVLcmb_oer7k9AwHIyAjwxkls33zr-Q6TU5A' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.552352"], ["target_id", 37], ["target_type", "User"], ["token", "1If0moz2ZVLcmb_oer7k9AwHIyAjwxkls33zr-Q6TU5A"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.552352"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.6ms Sent mail to user@example.com (1.9ms) Date: Mon, 07 Sep 2015 10:47:16 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecde9487bdc_e3b43feb594601fc75722@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.560629"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.560629"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 38 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.564508"], ["state", "pending"], ["target_id", 38], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.564508"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 45]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 38]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 38 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 38 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.574299"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.574299"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 39 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.578591"], ["state", "pending"], ["target_id", 39], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.578591"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 46]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 39]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 39 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 39]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 39 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 46 [["sent_time", "2015-09-07 00:47:16.583248"], ["state", "sent"], ["updated_at", "2015-09-07 00:47:16.585946"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 39 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.592585"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.592585"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 40 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.596491"], ["state", "pending"], ["target_id", 40], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.596491"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 40 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.600610"], ["state", "pending"], ["target_id", 40], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.600610"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 48]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 40]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 40 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 40]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 40 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 48 [["sent_time", "2015-09-07 00:47:16.605351"], ["state", "sent"], ["updated_at", "2015-09-07 00:47:16.608153"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 40]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 40 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 47 [["sent_time", "2015-09-07 00:47:16.610108"], ["state", "sent"], ["updated_at", "2015-09-07 00:47:16.612993"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 40 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 40 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.621138"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.621138"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 41 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.625553"], ["state", "read"], ["target_id", 41], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.625553"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 49]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 41]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 41 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.634276"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.634276"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 42 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 42 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.639156"], ["group_id", 2], ["state", "pending"], ["target_id", 42], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.639156"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 50]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 42]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 42 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 42]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 42 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 42 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 50 [["sent_time", "2015-09-07 00:47:16.645619"], ["state", "sent"], ["updated_at", "2015-09-07 00:47:16.649460"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 42 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 42 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 50]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 42]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 42 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 42 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 42 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.2ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.5ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 42 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'GQoY-oHY5C9YGb7Rqc8PjAlgD6nSBrseKGvrk2qGfWlQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:16.662980"], ["target_id", 42], ["target_type", "User"], ["token", "GQoY-oHY5C9YGb7Rqc8PjAlgD6nSBrseKGvrk2qGfWlQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.662980"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.8ms Sent mail to user@example.com (1.7ms) Date: Mon, 07 Sep 2015 10:47:16 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecde94a2d16_e3b43feb594601fc75846@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.671183"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.671183"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 43 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 43 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.677399"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 43], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.677399"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 43 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 43 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 51 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:16.682202"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 43 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 43 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 51 [["sent_time", "2015-09-07 00:47:16.683626"], ["updated_at", "2015-09-07 00:47:16.686184"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 51]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.693485"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.693485"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 44 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 44 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.697914"], ["group_id", 1], ["state", "pending"], ["target_id", 44], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.697914"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 44 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 52) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.703483"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.703483"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 45 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 45 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.709294"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 45], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.709294"]]  (0.7ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 45 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 45 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.8ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.727174"], ["group_id", 1], ["state", "pending"], ["target_id", 45], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.727174"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 45 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 54) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.736347"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.736347"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 46 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 46 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.741420"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 46], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.741420"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 46 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 46 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.746027"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 46], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.746027"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 46 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 46 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.750563"], ["group_id", 1], ["state", "pending"], ["target_id", 46], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.750563"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 46 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 57) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.756773"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.756773"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 47 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 47 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.761124"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 47], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.761124"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 47 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 47 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.765806"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 47], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.765806"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 47 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 47 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.770496"], ["group_id", 1], ["state", "pending"], ["target_id", 47], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.770496"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 47 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 60) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.777523"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.777523"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 48 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 48 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.782051"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 48], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.782051"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 48 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 48 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.786596"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 48], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.786596"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 48 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 48 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.791185"], ["group_id", 1], ["state", "pending"], ["target_id", 48], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.791185"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 48 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 63) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.797271"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.797271"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 49 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 49 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 14:47:16.798495"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 49], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.801897"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 49 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:47:16.804066') NewPostNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 49 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:47:16.804066') ORDER BY created_at DESC LIMIT 1  (0.6ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 49 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 49 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 00:47:16.812543"], ["group_id", 1], ["parent_id", 64], ["state", "pending"], ["target_id", 49], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.812543"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.817446"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.817446"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 50 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 50 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-05 23:47:16.818660"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 50], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.822259"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 50 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:47:16.824257')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 50 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 50 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.828140"], ["group_id", 1], ["state", "pending"], ["target_id", 50], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.828140"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.832331"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.832331"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 51 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 51 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-05 23:47:16.833434"], ["group_id", 1], ["state", "pending"], ["target_id", 51], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.836832"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 51 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:47:16.839098')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 51 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 51 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.844825"], ["group_id", 1], ["state", "pending"], ["target_id", 51], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.844825"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.849128"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.849128"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 52 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 52 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.853911"], ["group_id", 1], ["state", "pending"], ["target_id", 52], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.853911"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 52 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 70) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 52 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 70) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.863597"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.863597"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 53 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 53 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.868420"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 53], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.868420"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 53 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 53 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 71 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:16.873842"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 53 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 53 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 71 [["sent_time", "2015-09-07 00:47:16.875517"], ["updated_at", "2015-09-07 00:47:16.878422"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 53 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 53 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.883482"], ["group_id", 1], ["state", "pending"], ["target_id", 53], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.883482"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 53 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 72) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 53 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 72) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.891143"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.891143"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 54 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 54 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.896142"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 54], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.896142"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 54 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 54 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 73 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:16.900695"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 54 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 54 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 73 [["sent_time", "2015-09-07 00:47:16.901914"], ["updated_at", "2015-09-07 00:47:16.904750"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 54 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 54 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.911509"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 54], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.911509"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 54 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 54 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 74 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:16.916020"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 54 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 54 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 74 [["sent_time", "2015-09-07 00:47:16.917195"], ["updated_at", "2015-09-07 00:47:16.919866"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 54 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 54 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.924234"], ["group_id", 1], ["state", "pending"], ["target_id", 54], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.924234"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 54 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 75) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 54 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 75) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:16.932033"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:16.932033"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.936542"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 55], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.936542"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 76 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:16.941652"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 76 [["sent_time", "2015-09-07 00:47:16.943076"], ["updated_at", "2015-09-07 00:47:16.945692"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.950207"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 55], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.950207"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 77 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:16.954286"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 77 [["sent_time", "2015-09-07 00:47:16.955581"], ["updated_at", "2015-09-07 00:47:16.958307"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.962831"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 55], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.962831"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 78 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:16.967505"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 78 [["sent_time", "2015-09-07 00:47:16.968646"], ["updated_at", "2015-09-07 00:47:16.971414"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.977507"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 55], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.977507"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 79 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:16.982316"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 79 [["sent_time", "2015-09-07 00:47:16.983716"], ["updated_at", "2015-09-07 00:47:16.986843"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:16.991443"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 55], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:16.991443"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 80 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:16.996083"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 80 [["sent_time", "2015-09-07 00:47:16.997332"], ["updated_at", "2015-09-07 00:47:16.999915"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.004391"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 55], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.004391"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 81 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:17.009434"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 81 [["sent_time", "2015-09-07 00:47:17.010675"], ["updated_at", "2015-09-07 00:47:17.013216"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.017521"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 55], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.017521"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 82 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:17.021860"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 82 [["sent_time", "2015-09-07 00:47:17.023093"], ["updated_at", "2015-09-07 00:47:17.025497"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.030177"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 55], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.030177"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 83 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:17.034631"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 83 [["sent_time", "2015-09-07 00:47:17.035863"], ["updated_at", "2015-09-07 00:47:17.038544"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.043563"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 55], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.043563"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 84 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:17.047593"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 84 [["sent_time", "2015-09-07 00:47:17.048758"], ["updated_at", "2015-09-07 00:47:17.051301"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.056020"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 55], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.056020"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 85 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:17.060426"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 85 [["sent_time", "2015-09-07 00:47:17.061709"], ["updated_at", "2015-09-07 00:47:17.064203"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.069086"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 55], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.069086"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 86 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:17.073301"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 86 [["sent_time", "2015-09-07 00:47:17.074614"], ["updated_at", "2015-09-07 00:47:17.077353"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 55 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.081757"], ["group_id", 1], ["state", "pending"], ["target_id", 55], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.081757"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 55 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 87) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 55 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 87) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.089792"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.089792"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 56 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 56 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.094313"], ["group_id", 1], ["state", "pending"], ["target_id", 56], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.094313"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 56 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 56 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 56 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 88)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 56 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 56 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 88 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:17.106184"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.111391"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.111391"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 57 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 57 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.116382"], ["group_id", 1], ["state", "pending"], ["target_id", 57], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.116382"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 57 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 57 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 57 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 89)  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 57 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 57 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 89 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:17.125131"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.4ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.131192"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.131192"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 58 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 58 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.136379"], ["group_id", 1], ["state", "pending"], ["target_id", 58], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.136379"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 58 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 58 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 58 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 90)  (0.1ms) SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 58 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 58 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 90 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:17.152579"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 90]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.8ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.159358"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.159358"]]  (0.9ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 59 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 59 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.172621"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 59], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.172621"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 59 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 59 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:49:17.172621"], ["group_id", 1], ["state", "pending"], ["target_id", 59], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.178864"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 59 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 59 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 59 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 92)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 59 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 59 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 92 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:47:17.187342"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.192230"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.192230"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 60 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 60 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.196904"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 60], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.196904"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 60 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:47:17.198882') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 60 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:47:17.198882') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 60 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 60 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 00:49:17.196904"], ["group_id", 1], ["parent_id", 93], ["state", "pending"], ["target_id", 60], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.203958"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 94]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.209597"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.209597"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 61 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 61 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.214434"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 61], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.214434"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 61 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 61 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.219239"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 61], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.219239"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 61 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 61 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.223464"], ["group_id", 1], ["state", "pending"], ["target_id", 61], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.223464"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 61 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 61 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 61 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 97)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.233097"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.233097"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 62 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 62 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.237864"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 62], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.237864"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 62 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 62 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.242388"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 62], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.242388"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 62 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 62 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:47:17.246803"], ["group_id", 1], ["state", "pending"], ["target_id", 62], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.246803"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 62 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 62 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 62 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 100) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 100]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.256793"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.256793"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 63 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.269143"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.269143"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 64 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 64 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.277476"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.277476"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 65 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.283612"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.283612"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 66 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.287165"], ["state", "pending"], ["target_id", 66], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.287165"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 66) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:47:17.290806"], ["target_id", 66], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.290806"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 66 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.296166"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.296166"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 67 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.299535"], ["state", "pending"], ["target_id", 67], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.299535"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 67 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.304962"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.304962"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 68 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.308587"], ["state", "pending"], ["target_id", 68], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.308587"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 68) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:47:17.311915"], ["target_id", 68], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:47:17.311915"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 68 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 68 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.318268"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.318268"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 69 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.321738"], ["state", "pending"], ["target_id", 69], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.321738"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 69 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 69 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.328839"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.328839"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 70 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.332534"], ["state", "pending"], ["target_id", 70], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.332534"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 70) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.335779"], ["group_id", 1], ["target_id", 70], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.335779"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 70 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 70 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.344143"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.344143"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 71 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.347604"], ["state", "pending"], ["target_id", 71], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.347604"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 71) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:47:17.350505"], ["target_id", 71], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.350505"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 71 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 71 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.357548"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.357548"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 72 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.361340"], ["state", "pending"], ["target_id", 72], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.361340"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 72 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 72 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 107 [["group_id", 1], ["updated_at", "2015-09-07 00:47:17.366889"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 72 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 72 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.375261"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.375261"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 73 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.378395"], ["state", "pending"], ["target_id", 73], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.378395"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 108]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 73]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 73 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 73 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.387306"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.387306"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 74 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.390958"], ["state", "pending"], ["target_id", 74], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.390958"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 74) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:47:17.394127"], ["target_id", 74], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:47:17.394127"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 109]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 74]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 74 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 74 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.403093"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.403093"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 75 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.407837"], ["state", "pending"], ["target_id", 75], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.407837"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 75) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.411577"], ["group_id", 1], ["target_id", 75], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.411577"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 75 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 110]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 75]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 75 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.422425"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.422425"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 76 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.425710"], ["state", "pending"], ["target_id", 76], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.425710"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 76 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 76 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.432793"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.432793"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 77 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.436151"], ["state", "pending"], ["target_id", 77], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.436151"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 77) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:47:17.439553"], ["target_id", 77], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:47:17.439553"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 77 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 77 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.446838"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.446838"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 78 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.450172"], ["state", "pending"], ["target_id", 78], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.450172"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 78) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.453393"], ["group_id", 1], ["target_id", 78], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.453393"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 78 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 78 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.463103"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.463103"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 79 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.466721"], ["state", "pending"], ["target_id", 79], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.466721"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 79 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'VyRjmQ9y55XqNTVuCvpUHQCULE0VMF31bkbEHctZf0_A' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.470318"], ["target_id", 79], ["target_type", "User"], ["token", "VyRjmQ9y55XqNTVuCvpUHQCULE0VMF31bkbEHctZf0_A"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.470318"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.476922"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.476922"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 80 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.480599"], ["state", "pending"], ["target_id", 80], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.480599"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 80 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'QI1hu7z9-FIfD-oylH-YOglIyH4_MUKtASlHNZI1VdTQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.484301"], ["target_id", 80], ["target_type", "User"], ["token", "QI1hu7z9-FIfD-oylH-YOglIyH4_MUKtASlHNZI1VdTQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.484301"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 80 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.490935"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.490935"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 81 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.494470"], ["state", "pending"], ["target_id", 81], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.494470"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 81 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'FKT1n4fqEKJvgHyT0SgrJgx0MLy6A5zGJnjtKQqEagUw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.498855"], ["target_id", 81], ["target_type", "User"], ["token", "FKT1n4fqEKJvgHyT0SgrJgx0MLy6A5zGJnjtKQqEagUw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.498855"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 8 [["active", "f"], ["updated_at", "2015-09-07 00:47:17.501617"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 81 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Q0FKQNtqTgSsXa70UvbX-gISs0puffBvxTw-3cOuKXmA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.504970"], ["target_id", 81], ["target_type", "User"], ["token", "Q0FKQNtqTgSsXa70UvbX-gISs0puffBvxTw-3cOuKXmA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.504970"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.511973"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.511973"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 82 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 82) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:47:17.516203"], ["target_id", 82], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.516203"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.519688"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.519688"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 83 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 83) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:47:17.524206"], ["target_id", 83], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.524206"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 83 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.530676"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.530676"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 84) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:47:17.533724"], ["target_id", 84], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.533724"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 84 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 13]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.541474"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.541474"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (1.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 85) LIMIT 1 SQL (1.1ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:47:17.547989"], ["target_id", 85], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-07 00:47:17.547989"]]  (0.9ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 85 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.558394"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.558394"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (1.6ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 86) LIMIT 1 SQL (0.9ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.566485"], ["group_id", 1], ["target_id", 86], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.566485"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.7ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 86 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 15]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.578976"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.578976"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 87) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.582061"], ["group_id", 1], ["target_id", 87], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.582061"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 87 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.587874"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.587874"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 88) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:47:17.591314"], ["target_id", 88], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.591314"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 88 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.597238"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.597238"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 89) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:47:17.600599"], ["target_id", 89], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.600599"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 89 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.608045"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.608045"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 90) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:47:17.612006"], ["target_id", 90], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.612006"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 90) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 90 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 90 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 19]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 90 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.623520"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.623520"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 91 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.629067"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.629067"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '9wYbU54p-BSBN52_W7LFNAdPOOY7mP02XcX_VhIFNcCQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.631121"], ["target_id", 92], ["target_type", "User"], ["token", "9wYbU54p-BSBN52_W7LFNAdPOOY7mP02XcX_VhIFNcCQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.631121"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '9wYbU54p-BSBN52_W7LFNAdPOOY7mP02XcX_VhIFNcCQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.637262"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.637262"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '0rfUyEBCUVs4ObcwcKoWdADk4XPuUmWYxES8JjZCPabw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.639010"], ["target_id", 93], ["target_type", "User"], ["token", "0rfUyEBCUVs4ObcwcKoWdADk4XPuUmWYxES8JjZCPabw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.639010"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.7ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 11 [["active", "f"], ["updated_at", "2015-09-07 00:47:17.643720"]]  (0.6ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (1.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '0rfUyEBCUVs4ObcwcKoWdADk4XPuUmWYxES8JjZCPabw' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (1.0ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.655468"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.655468"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'nf_aYOJvjvqiAoNx-my_Gg_frzoqVrBjpIG083dIRNGQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.658012"], ["target_id", 94], ["target_type", "User"], ["token", "nf_aYOJvjvqiAoNx-my_Gg_frzoqVrBjpIG083dIRNGQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.658012"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.8ms) RELEASE SAVEPOINT active_record_1  (1.1ms) SAVEPOINT active_record_1 SQL (0.8ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 12 [["active", "f"], ["updated_at", "2015-09-07 00:47:17.666074"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.4ms) ROLLBACK  (0.4ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:47:17.676041"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:47:17.676041"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'G7lWNPaUXW4knEVSDyWKNg2_mqoOkR2852C2_36w4uoQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:47:17.679049"], ["target_id", 95], ["target_type", "User"], ["token", "G7lWNPaUXW4knEVSDyWKNg2_mqoOkR2852C2_36w4uoQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:47:17.679049"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:14.779103"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:14.779103"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.3ms) Completed 200 OK in 21ms (Views: 17.6ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:14.816903"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:14.816903"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 97 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:14.842648"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 97], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:14.842648"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 97 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (1.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 97 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 12ms  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:14.864430"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:14.864430"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 98 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:14.869832"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 98], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:14.869832"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 98 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 98 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:14.882611"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:14.882611"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 99 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:14.888833"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 99], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:14.888833"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 99 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:14.892625"], ["parent_id", 1], ["state", "pending"], ["target_id", 99], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:14.892625"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 99 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 99 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:14.906719"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:14.906719"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 100 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:14.913364"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 100], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:14.913364"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 100 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:14.916914"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 100], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:14.916914"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 100 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:14.920667"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 100], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:14.920667"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Completed 200 OK in 3ms (Views: 1.1ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:14.955848"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:14.955848"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 101 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:14.962146"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 101], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:14.962146"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 101 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:14.965613"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 101], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:14.965613"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 101 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:14.969726"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 101], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:14.969726"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"124"} NotifyUser::BaseNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 101 AND "notify_user_notifications"."target_type" = 'User' AND (id = '124') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 101]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 101 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 124 [["state", "read"], ["updated_at", "2015-09-07 00:48:14.982096"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 13ms (Views: 1.8ms | ActiveRecord: 2.0ms) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 124 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:14.998349"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:14.998349"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 102 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.004175"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 102], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.004175"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 102 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.007473"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 102], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.007473"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 102 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.011610"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 102], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.011610"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"127"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 102 AND "notify_user_notifications"."target_type" = 'User' AND (id = '127') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 102]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 102 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 127 [["state", "read"], ["updated_at", "2015-09-07 00:48:15.020049"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 7ms (Views: 0.3ms | ActiveRecord: 1.6ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"127"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 102 AND "notify_user_notifications"."target_type" = 'User' AND (id = '127') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.2ms | ActiveRecord: 1.9ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.029447"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.029447"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 103 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.035348"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 103], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.035348"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 103 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.039950"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 103], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.039950"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 103 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.043742"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 103], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.043742"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 103 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 103 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 3ms (Views: 0.9ms | ActiveRecord: 0.9ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 103 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.056160"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.056160"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 3ms (Views: 1.6ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.070046"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.070046"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 2ms (Views: 1.3ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.082396"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.082396"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 106 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.088209"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 106], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.088209"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["133"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 106 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('133')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 106 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('133')) Completed 500 Internal Server Error in 5ms  (0.7ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.103552"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.103552"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 107 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.109202"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 107], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.109202"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["134"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 107 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('134')) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 107 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('134')) Completed 500 Internal Server Error in 4ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.121089"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.121089"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 108 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.126357"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 108], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.126357"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 108 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 108 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 108) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:15.144890"], ["target_id", 108], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.144890"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 108 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 18ms (Views: 1.5ms | ActiveRecord: 1.8ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 108 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.155059"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.155059"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 109 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.160622"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 109], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.160622"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 109 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 109 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 109 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 5ms (Views: 1.7ms | ActiveRecord: 0.7ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 109 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.175949"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.175949"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 110 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.181577"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 110], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.181577"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 110 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 110) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:15.188872"], ["target_id", 110], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.188872"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 110 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 7ms (ActiveRecord: 1.6ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.197637"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.197637"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 111 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.203168"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 111], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.203168"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 111) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:15.206937"], ["target_id", 111], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.206937"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 111 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 22]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 4ms (ActiveRecord: 1.0ms) NotifyUser::Unsubscribe Load (0.2ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.219053"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.219053"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 112 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.224693"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 112], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.224693"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 112 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'BJnDj0in1xu-89PdZmXFygQi7M5d5dY_B_Q05Otafn-Q' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.234248"], ["target_id", 112], ["target_type", "User"], ["token", "BJnDj0in1xu-89PdZmXFygQi7M5d5dY_B_Q05Otafn-Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.234248"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"BJnDj0in1xu-89PdZmXFygQi7M5d5dY_B_Q05Otafn-Q"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'BJnDj0in1xu-89PdZmXFygQi7M5d5dY_B_Q05Otafn-Q' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'BJnDj0in1xu-89PdZmXFygQi7M5d5dY_B_Q05Otafn-Q' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 112]]  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 112) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:15.245005"], ["target_id", 112], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.245005"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 14 [["active", "f"], ["updated_at", "2015-09-07 00:48:15.247202"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.3ms | ActiveRecord: 2.5ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 239.4ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.4ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.6ms NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.526689"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.526689"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 113 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.530045"], ["state", "pending"], ["target_id", 113], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.530045"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.534539"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.534539"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 114 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.538536"], ["state", "pending"], ["target_id", 114], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.538536"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.542781"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.542781"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 115 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.546642"], ["state", "pending"], ["target_id", 115], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.546642"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.552097"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.552097"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 116 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.555270"], ["state", "pending"], ["target_id", 116], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.555270"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.559872"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.559872"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 117 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.563349"], ["state", "pending"], ["target_id", 117], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.563349"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 117 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.568873"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.568873"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 118 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.572382"], ["state", "pending"], ["target_id", 118], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.572382"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.576554"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.576554"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 119 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.579974"], ["state", "pending"], ["target_id", 119], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.579974"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.584229"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.584229"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 120 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.588406"], ["state", "pending"], ["target_id", 120], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.588406"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 120 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 147 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:48:15.591558"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.597087"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.597087"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 121 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.600998"], ["state", "pending"], ["target_id", 121], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.600998"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 121 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 148 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:48:15.604067"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.609587"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.609587"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 122 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.612793"], ["state", "pending"], ["target_id", 122], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.612793"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 122 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 149 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:48:15.615694"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.621048"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.621048"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 123 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.624635"], ["state", "pending"], ["target_id", 123], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.624635"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 123 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 150 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:48:15.627763"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.633824"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.633824"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 124 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.637137"], ["state", "pending"], ["target_id", 124], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.637137"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 124 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.643162"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.643162"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 125 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.646424"], ["state", "pending"], ["target_id", 125], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.646424"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 125 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 125 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 152 [["state", "sent"], ["updated_at", "2015-09-07 00:48:15.652069"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 125 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 152 [["sent_time", "2015-09-07 00:48:15.653314"], ["updated_at", "2015-09-07 00:48:15.654719"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.659089"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.659089"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 126 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.662402"], ["state", "pending"], ["target_id", 126], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.662402"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 126 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 126 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 153)  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 126 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 153 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:15.668872"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 153]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 126]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 126 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 126]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 126 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 153 [["sent_time", "2015-09-07 00:48:15.676397"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:15.679197"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 126 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 153]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 126]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 126 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 126 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 126 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '3F7nRqkljFSoi8iQ4D5ZIgNIH3pLsRtiwH_WylGyCnmA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.691077"], ["target_id", 126], ["target_type", "User"], ["token", "3F7nRqkljFSoi8iQ4D5ZIgNIH3pLsRtiwH_WylGyCnmA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.691077"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.1ms Sent mail to user@example.com (3.2ms) Date: Mon, 07 Sep 2015 10:48:15 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecdecfa9c7f_e61d3ff70c4601fc365d7@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.700178"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.700178"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 127 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.703638"], ["state", "pending_as_aggregation_parent"], ["target_id", 127], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.703638"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 127 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.0ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.711333"], ["state", "pending"], ["target_id", 127], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.711333"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 127 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 127 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 155)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.723060"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.723060"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 128 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.726582"], ["state", "pending"], ["target_id", 128], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.726582"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 128 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 128 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 156 [["state", "sent"], ["updated_at", "2015-09-07 00:48:15.730634"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 128 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 156 [["sent_time", "2015-09-07 00:48:15.731814"], ["updated_at", "2015-09-07 00:48:15.733496"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 156]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 128]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 128 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 128 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 128 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'tnfcbGc1bbuLYpeQje1QvA5BlpExkgHgS6oXdyY_ND7w' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.744419"], ["target_id", 128], ["target_type", "User"], ["token", "tnfcbGc1bbuLYpeQje1QvA5BlpExkgHgS6oXdyY_ND7w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.744419"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.5ms Sent mail to user@example.com (1.6ms) Date: Mon, 07 Sep 2015 10:48:15 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecdecfb6a94_e61d3ff70c4601fc366b9@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.752062"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.752062"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 129 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.755309"], ["state", "pending"], ["target_id", 129], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.755309"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 129 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 157 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-07 00:48:15.758556"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.763042"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.763042"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 130 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.766281"], ["state", "pending"], ["target_id", 130], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.766281"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 130) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:15.769633"], ["target_id", 130], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:48:15.769633"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 158]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 130]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 130 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 130 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.777969"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.777969"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 131 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.781520"], ["state", "pending"], ["target_id", 131], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.781520"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 159]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 131]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 131 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 131 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.791369"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.791369"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 132 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.794867"], ["state", "pending"], ["target_id", 132], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.794867"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 132 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 132 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 160 [["state", "sent"], ["updated_at", "2015-09-07 00:48:15.799172"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 132 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 160 [["sent_time", "2015-09-07 00:48:15.800420"], ["updated_at", "2015-09-07 00:48:15.801882"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 160]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 132]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 132 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 132 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 132 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'YxypJGrw-e9BHN181j56CAxBVcmx1T8sxO6e50ZAr8kg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.810883"], ["target_id", 132], ["target_type", "User"], ["token", "YxypJGrw-e9BHN181j56CAxBVcmx1T8sxO6e50ZAr8kg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.810883"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.5ms Sent mail to user@example.com (1.9ms) Date: Mon, 07 Sep 2015 10:48:15 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecdecfc6d75_e61d3ff70c4601fc367f7@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.818513"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.818513"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 133 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.821923"], ["state", "pending"], ["target_id", 133], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.821923"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 161]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 133]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 133 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 133 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.831461"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.831461"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 134 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.834635"], ["state", "pending"], ["target_id", 134], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.834635"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 162]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 134]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 134 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 134]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 134 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 162 [["sent_time", "2015-09-07 00:48:15.839427"], ["state", "sent"], ["updated_at", "2015-09-07 00:48:15.842059"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 134 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.848916"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.848916"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 135 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.852167"], ["state", "pending"], ["target_id", 135], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.852167"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 135 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.855616"], ["state", "pending"], ["target_id", 135], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.855616"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 164]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 135]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 135 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 135]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 135 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 164 [["sent_time", "2015-09-07 00:48:15.859856"], ["state", "sent"], ["updated_at", "2015-09-07 00:48:15.862553"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 135]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 135 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 163 [["sent_time", "2015-09-07 00:48:15.864663"], ["state", "sent"], ["updated_at", "2015-09-07 00:48:15.867277"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 135 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 135 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.876471"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.876471"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 136 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.879811"], ["state", "read"], ["target_id", 136], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.879811"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 165]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 136]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 136 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.887531"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.887531"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 137 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 137 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.892139"], ["group_id", 2], ["state", "pending"], ["target_id", 137], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.892139"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 166]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 137]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 137 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 137]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 137 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 137 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 166 [["sent_time", "2015-09-07 00:48:15.897952"], ["state", "sent"], ["updated_at", "2015-09-07 00:48:15.901358"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 137 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 137 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 166]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 137]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 137 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 137 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 137 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 137 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '45tbiCUv5DSywiqhbctsbALCrAsbQvWW843yLFV33cvQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:15.915238"], ["target_id", 137], ["target_type", "User"], ["token", "45tbiCUv5DSywiqhbctsbALCrAsbQvWW843yLFV33cvQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.915238"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.4ms Sent mail to user@example.com (2.0ms) Date: Mon, 07 Sep 2015 10:48:15 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecdecfe05c2_e61d3ff70c4601fc36857@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.923110"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.923110"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 138 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 138 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.927352"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 138], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.927352"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 138 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 138 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 167 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:15.931484"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 138 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 138 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 167 [["sent_time", "2015-09-07 00:48:15.932658"], ["updated_at", "2015-09-07 00:48:15.935026"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 167]]  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.942036"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.942036"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 139 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 139 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.946688"], ["group_id", 1], ["state", "pending"], ["target_id", 139], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.946688"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 139 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 168) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.952507"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.952507"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 140 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 140 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.957624"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 140], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.957624"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 140 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 140 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.962392"], ["group_id", 1], ["state", "pending"], ["target_id", 140], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.962392"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 140 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 170) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.969099"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.969099"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 141 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 141 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.973832"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 141], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.973832"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 141 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 141 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.978317"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 141], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.978317"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 141 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 141 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.982839"], ["group_id", 1], ["state", "pending"], ["target_id", 141], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.982839"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 141 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 173) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:15.988604"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:15.988604"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 142 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 142 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.993249"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 142], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.993249"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 142 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 142 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:15.997657"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 142], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:15.997657"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 142 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 142 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.002467"], ["group_id", 1], ["state", "pending"], ["target_id", 142], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.002467"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 142 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 176) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.009243"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.009243"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 143 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 143 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.013798"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 143], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.013798"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 143 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 143 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.018059"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 143], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.018059"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 143 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 143 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.022264"], ["group_id", 1], ["state", "pending"], ["target_id", 143], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.022264"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 143 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 179) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.028324"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.028324"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 144 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 144 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 14:48:16.029495"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 144], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.032618"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 144 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:48:16.034662') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 144 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:48:16.034662') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 144 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 144 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 00:48:16.040208"], ["group_id", 1], ["parent_id", 180], ["state", "pending"], ["target_id", 144], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.040208"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.044939"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.044939"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 145 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 145 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-05 23:48:16.046873"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 145], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.050399"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 145 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:48:16.052711')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 145 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 145 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.057604"], ["group_id", 1], ["state", "pending"], ["target_id", 145], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.057604"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.061941"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.061941"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 146 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 146 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-05 23:48:16.063099"], ["group_id", 1], ["state", "pending"], ["target_id", 146], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.066393"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 146 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:48:16.068577')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 146 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 146 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.072795"], ["group_id", 1], ["state", "pending"], ["target_id", 146], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.072795"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.077102"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.077102"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 147 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 147 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.081526"], ["group_id", 1], ["state", "pending"], ["target_id", 147], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.081526"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 147 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 186) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 147 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 186) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.089537"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.089537"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 148 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 148 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.094491"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 148], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.094491"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 148 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 148 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 187 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.098986"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 148 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 148 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 187 [["sent_time", "2015-09-07 00:48:16.100235"], ["updated_at", "2015-09-07 00:48:16.102685"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 148 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 148 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.107780"], ["group_id", 1], ["state", "pending"], ["target_id", 148], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.107780"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 148 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 188) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 148 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 188) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.114969"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.114969"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.119974"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 149], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.119974"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 189 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.125097"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 189 [["sent_time", "2015-09-07 00:48:16.126433"], ["updated_at", "2015-09-07 00:48:16.129050"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.134086"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 149], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.134086"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 190 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.138771"]]  (1.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 190 [["sent_time", "2015-09-07 00:48:16.140395"], ["updated_at", "2015-09-07 00:48:16.149704"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.155706"], ["group_id", 1], ["state", "pending"], ["target_id", 149], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.155706"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 149 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 191) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 149 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 191) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.163088"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.163088"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.167374"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.167374"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 192 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.171710"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 192 [["sent_time", "2015-09-07 00:48:16.173050"], ["updated_at", "2015-09-07 00:48:16.175962"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.180380"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.180380"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 193 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.184445"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 193 [["sent_time", "2015-09-07 00:48:16.185725"], ["updated_at", "2015-09-07 00:48:16.188160"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.192729"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.192729"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 194 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.197192"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 194 [["sent_time", "2015-09-07 00:48:16.198465"], ["updated_at", "2015-09-07 00:48:16.201011"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.206138"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.206138"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 195 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.210544"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 195 [["sent_time", "2015-09-07 00:48:16.211758"], ["updated_at", "2015-09-07 00:48:16.214192"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.218599"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.218599"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 196 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.222974"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 196 [["sent_time", "2015-09-07 00:48:16.224277"], ["updated_at", "2015-09-07 00:48:16.226787"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.231193"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.231193"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 197 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.235309"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 197 [["sent_time", "2015-09-07 00:48:16.236512"], ["updated_at", "2015-09-07 00:48:16.238917"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.244199"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.244199"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 198 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.248548"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 198 [["sent_time", "2015-09-07 00:48:16.249736"], ["updated_at", "2015-09-07 00:48:16.252077"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.256941"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.256941"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 199 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.261179"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 199 [["sent_time", "2015-09-07 00:48:16.262334"], ["updated_at", "2015-09-07 00:48:16.264884"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.269562"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.269562"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 200 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.273883"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 200 [["sent_time", "2015-09-07 00:48:16.275126"], ["updated_at", "2015-09-07 00:48:16.277537"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.282396"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.282396"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 201 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.286627"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 201 [["sent_time", "2015-09-07 00:48:16.287862"], ["updated_at", "2015-09-07 00:48:16.290801"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.295326"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.295326"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 202 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.299431"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 202 [["sent_time", "2015-09-07 00:48:16.300608"], ["updated_at", "2015-09-07 00:48:16.303424"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.314815"], ["group_id", 1], ["state", "pending"], ["target_id", 150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.314815"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 150 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 203) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 150 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 203) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.324289"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.324289"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 151 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 151 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.329091"], ["group_id", 1], ["state", "pending"], ["target_id", 151], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.329091"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 151 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 151 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 151 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 204)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 151 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 151 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 204 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.339264"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.344521"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.344521"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.350435"], ["group_id", 1], ["state", "pending"], ["target_id", 152], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.350435"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 152 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 205)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 205 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.359150"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.364707"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.364707"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.369023"], ["group_id", 1], ["state", "pending"], ["target_id", 153], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.369023"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 153 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 206)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 206 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.377224"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 206]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.382996"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.382996"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 154 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 154 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.387676"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 154], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.387676"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 154 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 154 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:50:16.387676"], ["group_id", 1], ["state", "pending"], ["target_id", 154], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.391928"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 154 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 154 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 154 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 208)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 154 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 154 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 208 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:16.400459"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.405727"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.405727"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 155 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 155 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.410319"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 155], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.410319"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 155 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:48:16.412391') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 155 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:48:16.412391') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 155 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 155 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 00:50:16.410319"], ["group_id", 1], ["parent_id", 209], ["state", "pending"], ["target_id", 155], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.417552"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 210]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.422683"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.422683"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 156 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 156 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.426927"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 156], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.426927"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 156 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 156 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.431538"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 156], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.431538"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 156 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 156 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.435763"], ["group_id", 1], ["state", "pending"], ["target_id", 156], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.435763"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 156 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 156 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 156 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 213)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.444007"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.444007"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 157 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 157 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.449277"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 157], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.449277"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 157 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 157 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.453663"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 157], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.453663"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 157 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 157 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:16.458051"], ["group_id", 1], ["state", "pending"], ["target_id", 157], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.458051"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 157 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 157 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 157 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 216) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 216]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.467091"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.467091"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 158 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.473467"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.473467"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.486447"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.486447"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.493626"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.493626"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 161 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.497185"], ["state", "pending"], ["target_id", 161], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.497185"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 161) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:16.500755"], ["target_id", 161], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.500755"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 161 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.506503"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.506503"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 162 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.509847"], ["state", "pending"], ["target_id", 162], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.509847"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 162 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.515466"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.515466"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 163 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.518731"], ["state", "pending"], ["target_id", 163], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.518731"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 163) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:16.521690"], ["target_id", 163], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:48:16.521690"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 163 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 163 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.528146"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.528146"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 164 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.532026"], ["state", "pending"], ["target_id", 164], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.532026"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 164 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 164 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.539405"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.539405"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 165 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.542828"], ["state", "pending"], ["target_id", 165], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.542828"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 165) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.546031"], ["group_id", 1], ["target_id", 165], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.546031"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 165 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 165 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.553467"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.553467"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 166 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.556630"], ["state", "pending"], ["target_id", 166], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.556630"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 166) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:16.560303"], ["target_id", 166], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.560303"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 166 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 166 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.567136"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.567136"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 167 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.571301"], ["state", "pending"], ["target_id", 167], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.571301"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 167 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 167 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 223 [["group_id", 1], ["updated_at", "2015-09-07 00:48:16.576209"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 167 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 167 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.582856"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.582856"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 168 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.586151"], ["state", "pending"], ["target_id", 168], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.586151"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 224]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 168]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 168 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 168 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.594501"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.594501"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 169 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.598255"], ["state", "pending"], ["target_id", 169], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.598255"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 169) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:16.601713"], ["target_id", 169], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:48:16.601713"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 225]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 169]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 169 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 169 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.610153"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.610153"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 170 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.613235"], ["state", "pending"], ["target_id", 170], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.613235"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 170) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.616497"], ["group_id", 1], ["target_id", 170], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.616497"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 170 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 226]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 170]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 170 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.627353"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.627353"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 171 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.630933"], ["state", "pending"], ["target_id", 171], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.630933"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 171 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 171 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.637574"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.637574"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 172 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.641204"], ["state", "pending"], ["target_id", 172], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.641204"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 172) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:16.644346"], ["target_id", 172], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:48:16.644346"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 172 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 172 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.651462"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.651462"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 173 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.655105"], ["state", "pending"], ["target_id", 173], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.655105"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 173) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.657936"], ["group_id", 1], ["target_id", 173], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.657936"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 173 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 173 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.666598"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.666598"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 174 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.670133"], ["state", "pending"], ["target_id", 174], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.670133"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 174 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '5apvrjokBT618d9XdGVzbg-5f-rGN78z3P5Vk2YT1Qjg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.674038"], ["target_id", 174], ["target_type", "User"], ["token", "5apvrjokBT618d9XdGVzbg-5f-rGN78z3P5Vk2YT1Qjg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.674038"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.679927"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.679927"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 175 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.683843"], ["state", "pending"], ["target_id", 175], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.683843"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 175 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '8qpCzIzxJYiligprEv5D3gk77HV0FWFHG2oR8ankLnZg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.687444"], ["target_id", 175], ["target_type", "User"], ["token", "8qpCzIzxJYiligprEv5D3gk77HV0FWFHG2oR8ankLnZg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.687444"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 175 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.694198"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.694198"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 176 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.697862"], ["state", "pending"], ["target_id", 176], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.697862"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 176 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'mJmz0wvNdhvt402ciod70gji57kHf6Hk0kIsvxXfrXEg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.701885"], ["target_id", 176], ["target_type", "User"], ["token", "mJmz0wvNdhvt402ciod70gji57kHf6Hk0kIsvxXfrXEg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.701885"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 21 [["active", "f"], ["updated_at", "2015-09-07 00:48:16.705595"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 176 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '0zfGEm1IlldU3v21SdAw0wRa73CIR5Xpc-sbdae3MBhg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.709847"], ["target_id", 176], ["target_type", "User"], ["token", "0zfGEm1IlldU3v21SdAw0wRa73CIR5Xpc-sbdae3MBhg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.709847"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.715314"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.715314"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 177 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 177) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:16.719431"], ["target_id", 177], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.719431"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.8ms) SAVEPOINT active_record_1 SQL (1.0ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.725204"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.725204"]]  (0.8ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 178 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.5ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.6ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 178) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:16.735844"], ["target_id", 178], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.735844"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 178 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.741775"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.741775"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 179) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:16.744917"], ["target_id", 179], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.744917"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 179 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 35]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.752008"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.752008"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 180) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:16.755495"], ["target_id", 180], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-07 00:48:16.755495"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 180 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.762064"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.762064"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 181) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.765073"], ["group_id", 1], ["target_id", 181], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.765073"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 181 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 37]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.771937"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.771937"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 182) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.774935"], ["group_id", 1], ["target_id", 182], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.774935"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 182 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.780842"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.780842"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 183) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:16.784146"], ["target_id", 183], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.784146"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 183 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.789297"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.789297"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 184) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:16.792531"], ["target_id", 184], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.792531"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 184 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.799142"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.799142"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 185) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:16.802324"], ["target_id", 185], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.802324"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 185) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 185 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 185 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 41]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 185 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.813393"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.813393"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 186 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.818313"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.818313"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'bbGnbHBvljzgpvzWUCJr9QuFpTTt-U8He45Z1AuB6pQQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.820193"], ["target_id", 187], ["target_type", "User"], ["token", "bbGnbHBvljzgpvzWUCJr9QuFpTTt-U8He45Z1AuB6pQQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.820193"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'bbGnbHBvljzgpvzWUCJr9QuFpTTt-U8He45Z1AuB6pQQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.825628"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.825628"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Ioqm66dA-1JVtUML45pQ0gMmCU0LgveB09PqZso4_KSA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.827387"], ["target_id", 188], ["target_type", "User"], ["token", "Ioqm66dA-1JVtUML45pQ0gMmCU0LgveB09PqZso4_KSA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.827387"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 24 [["active", "f"], ["updated_at", "2015-09-07 00:48:16.830538"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Ioqm66dA-1JVtUML45pQ0gMmCU0LgveB09PqZso4_KSA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.834782"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.834782"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.6ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'xDPqVqKhLlJ0AWSKdTCM-wNCLk2Mm2a2Y7qAuW8dX1gA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.837199"], ["target_id", 189], ["target_type", "User"], ["token", "xDPqVqKhLlJ0AWSKdTCM-wNCLk2Mm2a2Y7qAuW8dX1gA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.837199"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 25 [["active", "f"], ["updated_at", "2015-09-07 00:48:16.841591"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:16.844766"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:16.844766"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'tPfVEdDQy0VKRfIemiJ-nwKBkyYpgcMpcLiGHflQcBBA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:16.846883"], ["target_id", 190], ["target_type", "User"], ["token", "tPfVEdDQy0VKRfIemiJ-nwKBkyYpgcMpcLiGHflQcBBA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:16.846883"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:29.578606"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:29.578606"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.3ms) Completed 200 OK in 17ms (Views: 13.9ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:29.610504"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:29.610504"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 192 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:29.635454"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 192], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:29.635454"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 192 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (1.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 192 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 12ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:29.656162"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:29.656162"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 193 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:29.662581"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 193], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:29.662581"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 193 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 193 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:29.678140"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:29.678140"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 194 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:29.684399"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 194], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:29.684399"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 194 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:29.688737"], ["parent_id", 1], ["state", "pending"], ["target_id", 194], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:29.688737"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 194 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 194 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 7ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.9ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:29.705829"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:29.705829"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 195 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:29.713505"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 195], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:29.713505"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 195 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:29.724584"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 195], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:29.724584"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 195 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:29.731734"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 195], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:29.731734"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 195 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 171ms  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:29.914556"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:29.914556"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 196 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:29.922797"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 196], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:29.922797"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 196 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:29.926809"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 196], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:29.926809"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 196 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:29.931356"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 196], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:29.931356"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"240"} NotifyUser::BaseNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 196 AND "notify_user_notifications"."target_type" = 'User' AND (id = '240') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 196]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 196 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 240 [["state", "read"], ["updated_at", "2015-09-07 00:48:29.947383"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 16ms (Views: 1.5ms | ActiveRecord: 1.9ms) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 240 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:29.967044"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:29.967044"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 197 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:29.975106"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 197], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:29.975106"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 197 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:29.979191"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 197], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:29.979191"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 197 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:29.982892"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 197], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:29.982892"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"243"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 197 AND "notify_user_notifications"."target_type" = 'User' AND (id = '243') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 197]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 197 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 243 [["state", "read"], ["updated_at", "2015-09-07 00:48:29.993393"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.3ms | ActiveRecord: 1.8ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"243"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 197 AND "notify_user_notifications"."target_type" = 'User' AND (id = '243') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.2ms | ActiveRecord: 2.3ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.004804"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.004804"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 198 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.012608"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 198], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.012608"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 198 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.016562"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 198], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.016562"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 198 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.020518"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 198], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.020518"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 198 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 198 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 4ms (Views: 1.1ms | ActiveRecord: 0.9ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 198 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.034218"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.034218"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 4ms (Views: 2.8ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.052886"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.052886"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 3ms (Views: 1.6ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.068756"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.068756"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 201 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.076374"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 201], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.076374"]]  (0.5ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["249"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 201 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('249')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 201 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('249')) Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.093914"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.093914"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.102680"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 202], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.102680"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["250"]} SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 202 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('250')) NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 202 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('250')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.120206"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.120206"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.128354"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 203], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.128354"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 203) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:30.146680"], ["target_id", 203], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.146680"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 19ms (Views: 2.1ms | ActiveRecord: 1.9ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.159979"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.159979"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 204 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.167796"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 204], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.167796"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 204 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 204 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 204 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 6ms (Views: 2.2ms | ActiveRecord: 0.7ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 204 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.194500"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.194500"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 205 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.201222"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 205], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.201222"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 205 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 205) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:30.208617"], ["target_id", 205], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.208617"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 205 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 8ms (ActiveRecord: 1.8ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.219374"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.219374"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 206 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.226577"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 206], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.226577"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 206) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:30.229770"], ["target_id", 206], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.229770"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 206 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 44]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 5ms (ActiveRecord: 1.0ms) NotifyUser::Unsubscribe Load (0.2ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.243924"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.243924"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 207 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.249862"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 207], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.249862"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 207 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '3WUoBkSURiolxgUyB3VtRwTrGH3VAp86RVfUYKVaCXrQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.261213"], ["target_id", 207], ["target_type", "User"], ["token", "3WUoBkSURiolxgUyB3VtRwTrGH3VAp86RVfUYKVaCXrQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.261213"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"3WUoBkSURiolxgUyB3VtRwTrGH3VAp86RVfUYKVaCXrQ"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '3WUoBkSURiolxgUyB3VtRwTrGH3VAp86RVfUYKVaCXrQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '3WUoBkSURiolxgUyB3VtRwTrGH3VAp86RVfUYKVaCXrQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 207]]  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 207) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:30.271529"], ["target_id", 207], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.271529"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 27 [["active", "f"], ["updated_at", "2015-09-07 00:48:30.273539"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.3ms | ActiveRecord: 2.4ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 218.0ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.7ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.7ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.533176"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.533176"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 208 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.536955"], ["state", "pending"], ["target_id", 208], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.536955"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.541596"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.541596"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 209 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.546535"], ["state", "pending"], ["target_id", 209], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.546535"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.551269"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.551269"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.554752"], ["state", "pending"], ["target_id", 210], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.554752"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.559332"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.559332"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 211 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.562672"], ["state", "pending"], ["target_id", 211], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.562672"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.567257"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.567257"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 212 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.570779"], ["state", "pending"], ["target_id", 212], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.570779"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 212 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.576951"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.576951"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 213 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.580290"], ["state", "pending"], ["target_id", 213], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.580290"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.584816"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.584816"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 214 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.588537"], ["state", "pending"], ["target_id", 214], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.588537"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.592995"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.592995"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 215 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.597285"], ["state", "pending"], ["target_id", 215], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.597285"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 215 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 263 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:48:30.601166"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.607227"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.607227"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 216 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.610706"], ["state", "pending"], ["target_id", 216], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.610706"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 216 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 264 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:48:30.613646"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.618926"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.618926"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 217 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.622301"], ["state", "pending"], ["target_id", 217], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.622301"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 217 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 265 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:48:30.625448"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.630934"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.630934"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 218 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.634659"], ["state", "pending"], ["target_id", 218], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.634659"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 218 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 266 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:48:30.637793"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.644194"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.644194"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 219 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.647799"], ["state", "pending"], ["target_id", 219], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.647799"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 219 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.653849"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.653849"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 220 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.657410"], ["state", "pending"], ["target_id", 220], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.657410"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 220 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 220 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 268 [["state", "sent"], ["updated_at", "2015-09-07 00:48:30.662381"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 220 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 268 [["sent_time", "2015-09-07 00:48:30.663551"], ["updated_at", "2015-09-07 00:48:30.665066"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.669500"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.669500"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.673137"], ["state", "pending"], ["target_id", 221], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.673137"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 221 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 269)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 269 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:30.679989"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 269]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 221]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 221 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 221]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 269 [["sent_time", "2015-09-07 00:48:30.686908"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:30.689763"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 269]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 221]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 221 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'KcnjIoVBjgdlqpthqBXJ5AtVvtyMUQUfP8cNgL63Oq7Q' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.702488"], ["target_id", 221], ["target_type", "User"], ["token", "KcnjIoVBjgdlqpthqBXJ5AtVvtyMUQUfP8cNgL63Oq7Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.702488"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.5ms Sent mail to user@example.com (4.0ms) Date: Mon, 07 Sep 2015 10:48:30 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecdedeacaa2_e8293fd6a886020459820@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.712523"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.712523"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.723356"], ["state", "pending_as_aggregation_parent"], ["target_id", 222], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.723356"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.728327"], ["state", "pending"], ["target_id", 222], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.728327"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 222 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 271)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.736445"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.736445"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.739989"], ["state", "pending"], ["target_id", 223], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.739989"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 272 [["state", "sent"], ["updated_at", "2015-09-07 00:48:30.744451"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 272 [["sent_time", "2015-09-07 00:48:30.746020"], ["updated_at", "2015-09-07 00:48:30.747764"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 272]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 223]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 223 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'DqMtvpLJTz_iWUAMjJt-0Qp9YPujXCw0DHMIMFtapU9g' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.757660"], ["target_id", 223], ["target_type", "User"], ["token", "DqMtvpLJTz_iWUAMjJt-0Qp9YPujXCw0DHMIMFtapU9g"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.757660"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.7ms Sent mail to user@example.com (2.4ms) Date: Mon, 07 Sep 2015 10:48:30 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecdedeba1c6_e8293fd6a886020459955@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.767408"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.767408"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 224 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.770963"], ["state", "pending"], ["target_id", 224], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.770963"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 224 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 273 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-07 00:48:30.774258"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.778366"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.778366"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 225 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.781776"], ["state", "pending"], ["target_id", 225], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.781776"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 225) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:30.784681"], ["target_id", 225], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:48:30.784681"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 274]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 225]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 225 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 225 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.793237"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.793237"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 226 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.796955"], ["state", "pending"], ["target_id", 226], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.796955"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 275]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 226]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 226 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 226 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.805858"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.805858"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 227 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.810462"], ["state", "pending"], ["target_id", 227], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.810462"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 227 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 227 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 276 [["state", "sent"], ["updated_at", "2015-09-07 00:48:30.815601"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 227 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 276 [["sent_time", "2015-09-07 00:48:30.816902"], ["updated_at", "2015-09-07 00:48:30.818374"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 276]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 227]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 227 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 227 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 227 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'izrpsbMC4lF_nNEGDZ12FgSXNV9Wd8DYHAmw3tP2LfsQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.827199"], ["target_id", 227], ["target_type", "User"], ["token", "izrpsbMC4lF_nNEGDZ12FgSXNV9Wd8DYHAmw3tP2LfsQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.827199"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.8ms Sent mail to user@example.com (1.7ms) Date: Mon, 07 Sep 2015 10:48:30 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecdedecad1d_e8293fd6a8860204600c6@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.835051"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.835051"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 228 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.838888"], ["state", "pending"], ["target_id", 228], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.838888"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 277]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 228]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 228 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 228 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.848648"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.848648"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 229 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.852153"], ["state", "pending"], ["target_id", 229], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.852153"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 278]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 229]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 229 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 229]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 229 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 278 [["sent_time", "2015-09-07 00:48:30.856761"], ["state", "sent"], ["updated_at", "2015-09-07 00:48:30.859484"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 229 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.866671"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.866671"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 230 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.869971"], ["state", "pending"], ["target_id", 230], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.869971"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 230 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.873762"], ["state", "pending"], ["target_id", 230], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.873762"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 280]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 230]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 230 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 230]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 230 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 280 [["sent_time", "2015-09-07 00:48:30.878697"], ["state", "sent"], ["updated_at", "2015-09-07 00:48:30.881141"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 230]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 230 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 279 [["sent_time", "2015-09-07 00:48:30.882880"], ["state", "sent"], ["updated_at", "2015-09-07 00:48:30.885443"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 230 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 230 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.893572"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.893572"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 231 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.897722"], ["state", "read"], ["target_id", 231], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.897722"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 281]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 231]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 231 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.905305"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.905305"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 232 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 232 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.911265"], ["group_id", 2], ["state", "pending"], ["target_id", 232], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.911265"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 282]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 232]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 232 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 232]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 232 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 232 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 282 [["sent_time", "2015-09-07 00:48:30.917206"], ["state", "sent"], ["updated_at", "2015-09-07 00:48:30.921051"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 232 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 232 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 282]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 232]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 232 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 232 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 232 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 232 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'PKJSGR2WWE7b45qu3i18ywQlGgyoB1XkOM3cllNGeukg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:30.934501"], ["target_id", 232], ["target_type", "User"], ["token", "PKJSGR2WWE7b45qu3i18ywQlGgyoB1XkOM3cllNGeukg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.934501"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.4ms Sent mail to user@example.com (2.2ms) Date: Mon, 07 Sep 2015 10:48:30 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecdedee5382_e8293fd6a88602046015@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.944187"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.944187"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 233 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 233 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.950102"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 233], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.950102"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 233 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 233 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 283 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:30.955013"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 233 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 233 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 283 [["sent_time", "2015-09-07 00:48:30.956311"], ["updated_at", "2015-09-07 00:48:30.959194"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 283]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.967910"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.967910"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 234 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 234 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.972794"], ["group_id", 1], ["state", "pending"], ["target_id", 234], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.972794"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 234 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 284) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.979058"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.979058"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 235 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 235 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.983584"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 235], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.983584"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 235 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 235 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.988107"], ["group_id", 1], ["state", "pending"], ["target_id", 235], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.988107"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 235 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 286) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:30.993872"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:30.993872"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 236 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 236 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:30.999051"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 236], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:30.999051"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 236 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 236 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.004121"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 236], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.004121"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 236 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 236 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.009491"], ["group_id", 1], ["state", "pending"], ["target_id", 236], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.009491"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 236 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 289) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.016292"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.016292"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 237 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 237 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.020842"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 237], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.020842"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 237 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 237 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.025700"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 237], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.025700"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 237 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 237 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.030495"], ["group_id", 1], ["state", "pending"], ["target_id", 237], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.030495"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 237 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 292) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.048105"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.048105"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 238 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 238 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.053725"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 238], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.053725"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 238 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 238 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.062131"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 238], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.062131"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 238 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 238 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.069169"], ["group_id", 1], ["state", "pending"], ["target_id", 238], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.069169"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 238 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 295) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.4ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.079668"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.079668"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 239 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 239 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 14:48:31.081211"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 239], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.087087"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 239 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:48:31.089982') NewPostNotification Load (1.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 239 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:48:31.089982') ORDER BY created_at DESC LIMIT 1  (1.8ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 239 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 239 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 00:48:31.101557"], ["group_id", 1], ["parent_id", 296], ["state", "pending"], ["target_id", 239], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.101557"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.9ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.108887"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.108887"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 240 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 240 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-05 23:48:31.112192"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 240], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.118866"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 240 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:48:31.122219')  (3.0ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 240 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 240 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.137421"], ["group_id", 1], ["state", "pending"], ["target_id", 240], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.137421"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.151807"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.151807"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 241 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 241 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-05 23:48:31.154245"], ["group_id", 1], ["state", "pending"], ["target_id", 241], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.161954"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 241 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:48:31.165591')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 241 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 241 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.170268"], ["group_id", 1], ["state", "pending"], ["target_id", 241], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.170268"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.175628"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.175628"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 242 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 242 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.180763"], ["group_id", 1], ["state", "pending"], ["target_id", 242], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.180763"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 242 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 302) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 242 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 302) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.189229"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.189229"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 243 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 243 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.195119"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 243], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.195119"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 243 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 243 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 303 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.200177"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 243 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 243 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 303 [["sent_time", "2015-09-07 00:48:31.201591"], ["updated_at", "2015-09-07 00:48:31.204413"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 243 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 243 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.209643"], ["group_id", 1], ["state", "pending"], ["target_id", 243], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.209643"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 243 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 304) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 243 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 304) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.217748"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.217748"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.222410"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 244], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.222410"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 305 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.226802"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 305 [["sent_time", "2015-09-07 00:48:31.228150"], ["updated_at", "2015-09-07 00:48:31.231223"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.236315"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 244], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.236315"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 306 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.241175"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 306 [["sent_time", "2015-09-07 00:48:31.242759"], ["updated_at", "2015-09-07 00:48:31.246775"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.251493"], ["group_id", 1], ["state", "pending"], ["target_id", 244], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.251493"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 244 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 307) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 244 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 307) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.260634"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.260634"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.266180"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 245], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.266180"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 308 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.271201"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 308 [["sent_time", "2015-09-07 00:48:31.272451"], ["updated_at", "2015-09-07 00:48:31.276146"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.282640"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 245], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.282640"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 309 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.287624"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 309 [["sent_time", "2015-09-07 00:48:31.288911"], ["updated_at", "2015-09-07 00:48:31.291610"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.9ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.309576"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 245], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.309576"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 310 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.315884"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 310 [["sent_time", "2015-09-07 00:48:31.317341"], ["updated_at", "2015-09-07 00:48:31.320140"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.325047"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 245], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.325047"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 311 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.330002"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 311 [["sent_time", "2015-09-07 00:48:31.331289"], ["updated_at", "2015-09-07 00:48:31.333862"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.338652"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 245], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.338652"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 312 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.343227"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 312 [["sent_time", "2015-09-07 00:48:31.344522"], ["updated_at", "2015-09-07 00:48:31.347043"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.351686"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 245], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.351686"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 313 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.355727"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 313 [["sent_time", "2015-09-07 00:48:31.356949"], ["updated_at", "2015-09-07 00:48:31.359423"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.364197"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 245], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.364197"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 314 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.368269"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 314 [["sent_time", "2015-09-07 00:48:31.369440"], ["updated_at", "2015-09-07 00:48:31.372033"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.377033"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 245], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.377033"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 315 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.381416"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 315 [["sent_time", "2015-09-07 00:48:31.382639"], ["updated_at", "2015-09-07 00:48:31.385376"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.390116"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 245], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.390116"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 316 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.394531"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 316 [["sent_time", "2015-09-07 00:48:31.395938"], ["updated_at", "2015-09-07 00:48:31.398678"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.403236"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 245], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.403236"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 317 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.408013"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 317 [["sent_time", "2015-09-07 00:48:31.409330"], ["updated_at", "2015-09-07 00:48:31.412210"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.416958"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 245], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.416958"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 318 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.421342"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 318 [["sent_time", "2015-09-07 00:48:31.422663"], ["updated_at", "2015-09-07 00:48:31.425364"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.430394"], ["group_id", 1], ["state", "pending"], ["target_id", 245], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.430394"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 245 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 319) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 245 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 319) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.438937"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.438937"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 246 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 246 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.443763"], ["group_id", 1], ["state", "pending"], ["target_id", 246], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.443763"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 246 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 246 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 246 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 320)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 246 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 246 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 320 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.454557"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.459659"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.459659"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 247 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 247 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.464339"], ["group_id", 1], ["state", "pending"], ["target_id", 247], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.464339"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 247 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 247 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 247 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 321)  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 247 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 247 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 321 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.473770"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.479673"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.479673"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 248 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 248 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.484860"], ["group_id", 1], ["state", "pending"], ["target_id", 248], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.484860"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 248 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 248 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 248 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 322)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 248 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 248 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 322 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.493575"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 322]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.499948"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.499948"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 249 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 249 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.504617"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 249], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.504617"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 249 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 249 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:50:31.504617"], ["group_id", 1], ["state", "pending"], ["target_id", 249], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.509321"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 249 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 249 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 249 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 324)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 249 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 249 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 324 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:48:31.518841"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.524137"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.524137"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 250 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 250 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.529381"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 250], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.529381"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 250 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:48:31.531561') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 250 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:48:31.531561') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 250 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 250 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 00:50:31.529381"], ["group_id", 1], ["parent_id", 325], ["state", "pending"], ["target_id", 250], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.537190"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 326]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.542514"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.542514"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 251 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 251 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.547168"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 251], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.547168"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 251 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 251 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.551535"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 251], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.551535"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 251 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 251 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.556188"], ["group_id", 1], ["state", "pending"], ["target_id", 251], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.556188"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 251 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 251 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 251 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 329)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.564760"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.564760"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 252 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 252 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.569365"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 252], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.569365"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 252 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 252 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.573956"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 252], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.573956"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 252 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 252 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:48:31.579514"], ["group_id", 1], ["state", "pending"], ["target_id", 252], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.579514"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 252 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 252 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 252 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 332) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 332]]  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.589359"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.589359"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 253 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.595955"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.595955"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 254 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 254 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.603732"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.603732"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 255 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.609915"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.609915"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 256 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.613642"], ["state", "pending"], ["target_id", 256], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.613642"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 256) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:31.616922"], ["target_id", 256], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.616922"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 256 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.621839"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.621839"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 257 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.625094"], ["state", "pending"], ["target_id", 257], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.625094"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 257 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.631146"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.631146"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 258 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.634285"], ["state", "pending"], ["target_id", 258], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.634285"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 258) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:31.637097"], ["target_id", 258], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:48:31.637097"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 258 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 258 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.643304"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.643304"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 259 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.646475"], ["state", "pending"], ["target_id", 259], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.646475"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 259 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 259 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.652436"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.652436"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 260 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.655707"], ["state", "pending"], ["target_id", 260], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.655707"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 260) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.658893"], ["group_id", 1], ["target_id", 260], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.658893"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 260 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 260 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.666671"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.666671"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 261 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.669975"], ["state", "pending"], ["target_id", 261], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.669975"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 261) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:31.672878"], ["target_id", 261], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.672878"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 261 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 261 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.681541"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.681541"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 262 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.685175"], ["state", "pending"], ["target_id", 262], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.685175"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 262 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 262 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 339 [["group_id", 1], ["updated_at", "2015-09-07 00:48:31.689750"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 262 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 262 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.697187"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.697187"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 263 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.701034"], ["state", "pending"], ["target_id", 263], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.701034"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 340]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 263]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 263 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 263 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.709296"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.709296"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 264 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.713548"], ["state", "pending"], ["target_id", 264], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.713548"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (1.2ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 264) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:31.722495"], ["target_id", 264], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:48:31.722495"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 341]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 264]]  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 264 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 264 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.733233"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.733233"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 265 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.736706"], ["state", "pending"], ["target_id", 265], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.736706"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 265) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.739470"], ["group_id", 1], ["target_id", 265], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.739470"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 265 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 342]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 265]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 265 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.749206"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.749206"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 266 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.752653"], ["state", "pending"], ["target_id", 266], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.752653"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 266 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 266 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.759554"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.759554"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 267 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.763040"], ["state", "pending"], ["target_id", 267], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.763040"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 267) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:31.766428"], ["target_id", 267], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:48:31.766428"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 267 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 267 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.772925"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.772925"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 268 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.777307"], ["state", "pending"], ["target_id", 268], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.777307"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 268) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.780480"], ["group_id", 1], ["target_id", 268], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.780480"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 268 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 268 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.787716"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.787716"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 269 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.791034"], ["state", "pending"], ["target_id", 269], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.791034"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 269 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'BHvTvpW0as_lUlsb5Y3HGQk_Y14RPNZNweGNIw1ZgbTA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.794605"], ["target_id", 269], ["target_type", "User"], ["token", "BHvTvpW0as_lUlsb5Y3HGQk_Y14RPNZNweGNIw1ZgbTA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.794605"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.799312"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.799312"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 270 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.802739"], ["state", "pending"], ["target_id", 270], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.802739"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 270 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'dqlMrqiT-Q-eEXCvoyZYBAta9rroOq_tLLS1vWLdEXFQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.805825"], ["target_id", 270], ["target_type", "User"], ["token", "dqlMrqiT-Q-eEXCvoyZYBAta9rroOq_tLLS1vWLdEXFQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.805825"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 270 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.812273"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.812273"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 271 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.816216"], ["state", "pending"], ["target_id", 271], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.816216"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 271 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'uUgxO2jfoR311zKgzb_7YQCWXMhxZObaEYgZXVyOySNw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.819622"], ["target_id", 271], ["target_type", "User"], ["token", "uUgxO2jfoR311zKgzb_7YQCWXMhxZObaEYgZXVyOySNw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.819622"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 34 [["active", "f"], ["updated_at", "2015-09-07 00:48:31.822147"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 271 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '3GlnJPrqsFH8b6pDLnibpgOoAGRma19Lh3YZrgkODWCQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.825236"], ["target_id", 271], ["target_type", "User"], ["token", "3GlnJPrqsFH8b6pDLnibpgOoAGRma19Lh3YZrgkODWCQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.825236"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.831597"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.831597"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 272 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 272) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:31.835536"], ["target_id", 272], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.835536"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.839019"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.839019"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 273 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 273) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:31.843000"], ["target_id", 273], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.843000"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 273 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.848381"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.848381"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 274) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:31.851159"], ["target_id", 274], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.851159"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 274 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 57]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.857267"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.857267"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 275) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:31.859936"], ["target_id", 275], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-07 00:48:31.859936"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 275 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.865454"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.865454"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 276) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.868490"], ["group_id", 1], ["target_id", 276], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.868490"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 276 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 59]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.874799"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.874799"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 277) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.878688"], ["group_id", 1], ["target_id", 277], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.878688"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 277 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.884700"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.884700"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 278) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:31.887470"], ["target_id", 278], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.887470"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 278 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.892456"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.892456"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 279) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:31.895531"], ["target_id", 279], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.895531"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 279 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.901449"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.901449"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 280) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:48:31.904353"], ["target_id", 280], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.904353"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 280) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 280 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 280 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 63]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 280 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.915902"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.915902"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 281 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.921270"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.921270"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ZCmFh-qJyXGq2BcrtEMNBAyg4R3MpeOGoJtdutaP8Ccw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.923537"], ["target_id", 282], ["target_type", "User"], ["token", "ZCmFh-qJyXGq2BcrtEMNBAyg4R3MpeOGoJtdutaP8Ccw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.923537"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ZCmFh-qJyXGq2BcrtEMNBAyg4R3MpeOGoJtdutaP8Ccw' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.930763"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.930763"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '5HrkkW9Z4r8CrzfrGHaKhQT6iJafIDXoAFC0NJtHOJXQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.932682"], ["target_id", 283], ["target_type", "User"], ["token", "5HrkkW9Z4r8CrzfrGHaKhQT6iJafIDXoAFC0NJtHOJXQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.932682"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 37 [["active", "f"], ["updated_at", "2015-09-07 00:48:31.935851"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '5HrkkW9Z4r8CrzfrGHaKhQT6iJafIDXoAFC0NJtHOJXQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.939700"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.939700"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Cioh6KefKZmbZU3lBZ68mQrK1mcJwNSjW3_sXCPznaTg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.941892"], ["target_id", 284], ["target_type", "User"], ["token", "Cioh6KefKZmbZU3lBZ68mQrK1mcJwNSjW3_sXCPznaTg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.941892"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 38 [["active", "f"], ["updated_at", "2015-09-07 00:48:31.945367"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:48:31.948463"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:48:31.948463"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'sCTsiuKZlywCxbKEinvsoA1i_0ixcDVsZKFeRkXisRKw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:48:31.950266"], ["target_id", 285], ["target_type", "User"], ["token", "sCTsiuKZlywCxbKEinvsoA1i_0ixcDVsZKFeRkXisRKw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:48:31.950266"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:51.325521"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:51.325521"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.3ms) Completed 200 OK in 21ms (Views: 17.4ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:51.362437"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:51.362437"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 287 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.397767"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 287], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.397767"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 287 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 287 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 12ms  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:51.421833"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:51.421833"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 288 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.428222"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 288], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.428222"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 288 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 288 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:51.443650"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:51.443650"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 289 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.450266"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 289], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.450266"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 289 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.454539"], ["parent_id", 1], ["state", "pending"], ["target_id", 289], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.454539"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 289 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 289 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 9ms  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:51.475868"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:51.475868"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 290 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.486516"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 290], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.486516"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 290 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.492175"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 290], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.492175"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 290 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.498123"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 290], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.498123"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 290 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 176ms  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:51.687436"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:51.687436"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 291 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.696404"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 291], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.696404"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 291 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.700420"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 291], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.700420"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 291 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.703835"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 291], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.703835"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"356"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 291 AND "notify_user_notifications"."target_type" = 'User' AND (id = '356') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 291]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 291 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 356 [["state", "read"], ["updated_at", "2015-09-07 00:51:51.715299"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 12ms (Views: 1.1ms | ActiveRecord: 1.9ms) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 356 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:51.726419"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:51.726419"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.733103"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 292], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.733103"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.736982"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 292], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.736982"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.760071"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 292], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.760071"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"359"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 292 AND "notify_user_notifications"."target_type" = 'User' AND (id = '359') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.3ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 292]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 359 [["state", "read"], ["updated_at", "2015-09-07 00:51:51.770954"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.3ms | ActiveRecord: 1.9ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"359"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 292 AND "notify_user_notifications"."target_type" = 'User' AND (id = '359') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.2ms | ActiveRecord: 2.3ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:51.783137"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:51.783137"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 293 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.789982"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 293], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.789982"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 293 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.794183"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 293], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.794183"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 293 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.797997"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 293], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.797997"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 293 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 293 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 4ms (Views: 1.0ms | ActiveRecord: 1.0ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 293 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:51.812345"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:51.812345"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 3ms (Views: 1.6ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:51.828468"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:51.828468"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 4ms (Views: 2.2ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:51.845172"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:51.845172"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 296 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.852328"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 296], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.852328"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["365"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 296 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('365')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 296 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('365')) Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:51.870922"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:51.870922"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 297 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.9ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.882176"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 297], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.882176"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["366"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 297 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('366')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 297 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('366')) Completed 500 Internal Server Error in 7ms  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:51.910473"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:51.910473"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 298 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.919170"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 298], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.919170"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 298 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 298 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 298) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:51.940983"], ["target_id", 298], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.940983"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 298 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 24ms (Views: 4.6ms | ActiveRecord: 1.8ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 298 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:51.960993"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:51.960993"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 299 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:51.971585"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 299], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:51.971585"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 299 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.6ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 299 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 299 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 10ms (Views: 2.7ms | ActiveRecord: 1.0ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 299 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:51.996540"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:51.996540"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 300 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.005439"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 300], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.005439"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 300 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 300) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:52.013547"], ["target_id", 300], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.013547"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 300 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 8ms (ActiveRecord: 1.8ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.025694"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.025694"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 301 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.039949"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 301], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.039949"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 301) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:52.042942"], ["target_id", 301], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.042942"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (1.1ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 301 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 66]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 6ms (ActiveRecord: 1.8ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.057112"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.057112"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 302 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.062594"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 302], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.062594"]]  (0.8ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.7ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 302 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'YCAq4ST25nvcPgVQ643hBQFtjdnGynPuY7xIM_l6DfWQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.073975"], ["target_id", 302], ["target_type", "User"], ["token", "YCAq4ST25nvcPgVQ643hBQFtjdnGynPuY7xIM_l6DfWQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.073975"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"YCAq4ST25nvcPgVQ643hBQFtjdnGynPuY7xIM_l6DfWQ"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'YCAq4ST25nvcPgVQ643hBQFtjdnGynPuY7xIM_l6DfWQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'YCAq4ST25nvcPgVQ643hBQFtjdnGynPuY7xIM_l6DfWQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 302]]  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 302) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:52.083842"], ["target_id", 302], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.083842"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 40 [["active", "f"], ["updated_at", "2015-09-07 00:51:52.085609"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.3ms | ActiveRecord: 2.6ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 155.6ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.0ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.6ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.282817"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.282817"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 303 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.286367"], ["state", "pending"], ["target_id", 303], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.286367"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.291282"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.291282"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 304 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.295573"], ["state", "pending"], ["target_id", 304], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.295573"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.301110"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.301110"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 305 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.304746"], ["state", "pending"], ["target_id", 305], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.304746"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.309097"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.309097"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 306 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.312228"], ["state", "pending"], ["target_id", 306], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.312228"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (1.0ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.318332"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.318332"]]  (0.8ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 307 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.327620"], ["state", "pending"], ["target_id", 307], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.327620"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 307 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.333722"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.333722"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 308 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.337650"], ["state", "pending"], ["target_id", 308], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.337650"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.341744"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.341744"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.345067"], ["state", "pending"], ["target_id", 309], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.345067"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.349860"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.349860"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.353174"], ["state", "pending"], ["target_id", 310], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.353174"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 379 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:51:52.356184"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.361580"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.361580"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 311 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.365013"], ["state", "pending"], ["target_id", 311], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.365013"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 311 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 380 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:51:52.368010"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.373215"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.373215"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 312 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.376513"], ["state", "pending"], ["target_id", 312], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.376513"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 312 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 381 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:51:52.379582"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.384907"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.384907"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 313 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.388141"], ["state", "pending"], ["target_id", 313], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.388141"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 313 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 382 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:51:52.391308"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.396663"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.396663"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 314 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.400638"], ["state", "pending"], ["target_id", 314], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.400638"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 314 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.406340"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.406340"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 315 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.409917"], ["state", "pending"], ["target_id", 315], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.409917"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 315 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 315 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 384 [["state", "sent"], ["updated_at", "2015-09-07 00:51:52.414883"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 315 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 384 [["sent_time", "2015-09-07 00:51:52.416066"], ["updated_at", "2015-09-07 00:51:52.417432"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.421725"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.421725"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.424875"], ["state", "pending"], ["target_id", 316], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.424875"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 316 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 385)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 385 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:52.431169"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 385]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 316]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 316 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 316]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 385 [["sent_time", "2015-09-07 00:51:52.437786"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:52.440580"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 385]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 316]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 316 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'KlULluSMk8AOL8718JdANgZdO6IuGRReSLV2fodecK4w' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.452232"], ["target_id", 316], ["target_type", "User"], ["token", "KlULluSMk8AOL8718JdANgZdO6IuGRReSLV2fodecK4w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.452232"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.3ms Sent mail to user@example.com (3.2ms) Date: Mon, 07 Sep 2015 10:51:52 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecdfa86f963_eb613fe18c460200275b9@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.461660"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.461660"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 317 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.465569"], ["state", "pending_as_aggregation_parent"], ["target_id", 317], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.465569"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 317 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.469988"], ["state", "pending"], ["target_id", 317], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.469988"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 317 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 317 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 387)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.477062"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.477062"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 318 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.480423"], ["state", "pending"], ["target_id", 318], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.480423"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 318 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 318 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 388 [["state", "sent"], ["updated_at", "2015-09-07 00:51:52.484860"]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 318 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 388 [["sent_time", "2015-09-07 00:51:52.486229"], ["updated_at", "2015-09-07 00:51:52.487864"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 388]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 318]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 318 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 318 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 318 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.5ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'wgvUFc5ur8ASkHnO6MNkVAZt1C5RnWLE2rNfY-gPnhAA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.497775"], ["target_id", 318], ["target_type", "User"], ["token", "wgvUFc5ur8ASkHnO6MNkVAZt1C5RnWLE2rNfY-gPnhAA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.497775"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 7.4ms Sent mail to user@example.com (1.6ms) Date: Mon, 07 Sep 2015 10:51:52 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecdfa87abda_eb613fe18c46020027691@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.506578"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.506578"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 319 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.509822"], ["state", "pending"], ["target_id", 319], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.509822"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 319 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 389 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-07 00:51:52.513235"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.517896"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.517896"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 320 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.521708"], ["state", "pending"], ["target_id", 320], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.521708"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 320) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:52.524965"], ["target_id", 320], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:51:52.524965"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 390]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 320]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 320 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 320 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.6ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.534275"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.534275"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 321 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.537730"], ["state", "pending"], ["target_id", 321], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.537730"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 391]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 321]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 321 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 321 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.546393"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.546393"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 322 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.551446"], ["state", "pending"], ["target_id", 322], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.551446"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 322 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 322 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 392 [["state", "sent"], ["updated_at", "2015-09-07 00:51:52.556235"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 322 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 392 [["sent_time", "2015-09-07 00:51:52.557497"], ["updated_at", "2015-09-07 00:51:52.558927"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 392]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 322]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 322 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 322 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 322 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '0ivNSANtSgjehnKBL9QMQg8I1iJHDhwOOW9wV4RojEDw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.569521"], ["target_id", 322], ["target_type", "User"], ["token", "0ivNSANtSgjehnKBL9QMQg8I1iJHDhwOOW9wV4RojEDw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.569521"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 7.1ms Sent mail to user@example.com (1.7ms) Date: Mon, 07 Sep 2015 10:51:52 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecdfa88bf8f_eb613fe18c460200277f3@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.577299"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.577299"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 323 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.580889"], ["state", "pending"], ["target_id", 323], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.580889"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 393]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 323]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 323 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 323 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.590296"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.590296"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 324 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.593820"], ["state", "pending"], ["target_id", 324], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.593820"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 394]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 324]] NewPostNotification Load (1.0ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 324 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 324]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 324 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 394 [["sent_time", "2015-09-07 00:51:52.599932"], ["state", "sent"], ["updated_at", "2015-09-07 00:51:52.602833"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 324 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.610039"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.610039"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.613316"], ["state", "pending"], ["target_id", 325], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.613316"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.617247"], ["state", "pending"], ["target_id", 325], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.617247"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 396]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 325]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 325 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 325]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 396 [["sent_time", "2015-09-07 00:51:52.622122"], ["state", "sent"], ["updated_at", "2015-09-07 00:51:52.624680"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 325]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 395 [["sent_time", "2015-09-07 00:51:52.626472"], ["state", "sent"], ["updated_at", "2015-09-07 00:51:52.629003"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.638971"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.638971"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 326 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.642379"], ["state", "read"], ["target_id", 326], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.642379"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 397]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 326]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 326 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.4ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.651575"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.651575"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.655977"], ["group_id", 2], ["state", "pending"], ["target_id", 327], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.655977"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 398]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 327]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 327 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 327]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 398 [["sent_time", "2015-09-07 00:51:52.661348"], ["state", "sent"], ["updated_at", "2015-09-07 00:51:52.665022"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 398]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 327]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 327 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'pD0kOQNRvVLIMaJ_MrYr_gaMmrVL8dUUpTabinxIOWkA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:52.677523"], ["target_id", 327], ["target_type", "User"], ["token", "pD0kOQNRvVLIMaJ_MrYr_gaMmrVL8dUUpTabinxIOWkA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.677523"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.8ms Sent mail to user@example.com (1.6ms) Date: Mon, 07 Sep 2015 10:51:52 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecdfa8a647b_eb613fe18c460200278f4@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.685787"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.685787"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 328 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 328 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.690778"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 328], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.690778"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 328 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 328 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 399 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:52.695302"]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 328 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 328 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 399 [["sent_time", "2015-09-07 00:51:52.696661"], ["updated_at", "2015-09-07 00:51:52.700961"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 399]]  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.708268"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.708268"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 329 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 329 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.712616"], ["group_id", 1], ["state", "pending"], ["target_id", 329], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.712616"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 329 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 400) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.719616"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.719616"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 330 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 330 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.724646"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 330], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.724646"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 330 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 330 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.729317"], ["group_id", 1], ["state", "pending"], ["target_id", 330], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.729317"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 330 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 402) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.6ms) ROLLBACK  (0.9ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.744609"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.744609"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 331 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 331 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.749574"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 331], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.749574"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 331 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 331 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.755800"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 331], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.755800"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 331 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 331 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.760546"], ["group_id", 1], ["state", "pending"], ["target_id", 331], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.760546"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 331 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 405) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.767024"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.767024"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 332 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 332 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.772069"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 332], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.772069"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 332 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 332 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.776619"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 332], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.776619"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 332 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 332 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.781200"], ["group_id", 1], ["state", "pending"], ["target_id", 332], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.781200"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 332 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 408) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.787223"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.787223"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 333 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 333 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.793103"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 333], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.793103"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 333 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 333 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.797736"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 333], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.797736"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 333 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 333 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.803731"], ["group_id", 1], ["state", "pending"], ["target_id", 333], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.803731"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 333 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 411) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.809420"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.809420"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 334 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 334 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.9ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 14:51:52.810820"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 334], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.814294"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 334 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:51:52.817950') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 334 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:51:52.817950') ORDER BY created_at DESC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 334 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 334 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 00:51:52.823543"], ["group_id", 1], ["parent_id", 412], ["state", "pending"], ["target_id", 334], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.823543"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.828902"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.828902"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 335 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 335 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-05 23:51:52.830135"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 335], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.833570"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 335 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:51:52.836200')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 335 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 335 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.840411"], ["group_id", 1], ["state", "pending"], ["target_id", 335], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.840411"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.844495"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.844495"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 336 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 336 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-05 23:51:52.845531"], ["group_id", 1], ["state", "pending"], ["target_id", 336], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.849251"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 336 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:51:52.852319')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 336 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 336 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.857651"], ["group_id", 1], ["state", "pending"], ["target_id", 336], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.857651"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.863089"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.863089"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 337 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 337 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.870182"], ["group_id", 1], ["state", "pending"], ["target_id", 337], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.870182"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 337 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 418) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 337 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 418) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.8ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.893786"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.893786"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 338 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 338 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.901511"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 338], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.901511"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 338 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 338 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 419 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:52.909443"]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 338 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 338 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 419 [["sent_time", "2015-09-07 00:51:52.911358"], ["updated_at", "2015-09-07 00:51:52.917095"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 338 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 338 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.925622"], ["group_id", 1], ["state", "pending"], ["target_id", 338], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.925622"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 338 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 420) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (1.0ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 338 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 420) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.941114"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.941114"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.947533"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 339], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.947533"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 421 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:52.953159"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 421 [["sent_time", "2015-09-07 00:51:52.954722"], ["updated_at", "2015-09-07 00:51:52.957726"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.962488"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 339], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.962488"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 422 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:52.968301"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 422 [["sent_time", "2015-09-07 00:51:52.969452"], ["updated_at", "2015-09-07 00:51:52.972649"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.978220"], ["group_id", 1], ["state", "pending"], ["target_id", 339], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.978220"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 339 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 423) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 339 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 423) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:52.989030"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:52.989030"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:52.994124"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 340], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:52.994124"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 424 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:52.998828"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 424 [["sent_time", "2015-09-07 00:51:53.001107"], ["updated_at", "2015-09-07 00:51:53.004211"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.008735"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 340], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.008735"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 425 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:53.013260"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 425 [["sent_time", "2015-09-07 00:51:53.014544"], ["updated_at", "2015-09-07 00:51:53.017657"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.023304"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 340], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.023304"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 426 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:53.028402"]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 426 [["sent_time", "2015-09-07 00:51:53.029821"], ["updated_at", "2015-09-07 00:51:53.034528"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.039877"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 340], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.039877"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 427 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:53.044259"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 427 [["sent_time", "2015-09-07 00:51:53.045540"], ["updated_at", "2015-09-07 00:51:53.048274"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.053652"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 340], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.053652"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 428 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:53.058660"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 428 [["sent_time", "2015-09-07 00:51:53.060088"], ["updated_at", "2015-09-07 00:51:53.063158"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.069409"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 340], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.069409"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 429 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:53.074491"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 429 [["sent_time", "2015-09-07 00:51:53.075914"], ["updated_at", "2015-09-07 00:51:53.078818"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.084274"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 340], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.084274"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 430 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:53.088786"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 430 [["sent_time", "2015-09-07 00:51:53.090004"], ["updated_at", "2015-09-07 00:51:53.092972"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.097913"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 340], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.097913"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 431 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:53.102560"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 431 [["sent_time", "2015-09-07 00:51:53.103977"], ["updated_at", "2015-09-07 00:51:53.106930"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.111817"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 340], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.111817"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 432 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:53.116531"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 432 [["sent_time", "2015-09-07 00:51:53.117807"], ["updated_at", "2015-09-07 00:51:53.120737"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.125775"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 340], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.125775"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 433 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:53.130753"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 433 [["sent_time", "2015-09-07 00:51:53.131980"], ["updated_at", "2015-09-07 00:51:53.135091"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.139893"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 340], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.139893"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 434 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:53.144458"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 434 [["sent_time", "2015-09-07 00:51:53.145901"], ["updated_at", "2015-09-07 00:51:53.148767"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.154470"], ["group_id", 1], ["state", "pending"], ["target_id", 340], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.154470"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 340 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 435) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 340 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 435) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.162503"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.162503"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 341 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 341 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.167253"], ["group_id", 1], ["state", "pending"], ["target_id", 341], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.167253"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 341 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 341 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 341 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 436)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 341 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 341 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 436 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:53.177274"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.182032"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.182032"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 342 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 342 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.187001"], ["group_id", 1], ["state", "pending"], ["target_id", 342], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.187001"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 342 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 342 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 342 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 437)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 342 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 342 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 437 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:53.195854"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.202277"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.202277"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 343 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 343 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.207118"], ["group_id", 1], ["state", "pending"], ["target_id", 343], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.207118"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 343 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 343 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 343 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 438)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 343 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 343 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 438 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:53.215720"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 438]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.222168"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.222168"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 344 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 344 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.226630"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 344], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.226630"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 344 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 344 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:53:53.226630"], ["group_id", 1], ["state", "pending"], ["target_id", 344], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.231045"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 344 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 344 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 344 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 440)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 344 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 344 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 440 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:51:53.240295"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.245119"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.245119"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 345 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 345 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.251092"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 345], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.251092"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 345 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:51:53.253411') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 345 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:51:53.253411') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 345 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 345 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 00:53:53.251092"], ["group_id", 1], ["parent_id", 441], ["state", "pending"], ["target_id", 345], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.258907"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 442]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.264066"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.264066"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 346 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 346 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.269020"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 346], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.269020"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 346 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 346 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.273525"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 346], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.273525"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 346 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 346 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.278091"], ["group_id", 1], ["state", "pending"], ["target_id", 346], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.278091"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 346 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 346 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 346 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 445)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.287831"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.287831"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.292317"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 347], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.292317"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.296628"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 347], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.296628"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:51:53.302588"], ["group_id", 1], ["state", "pending"], ["target_id", 347], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.302588"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 347 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 448) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 448]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.312039"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.312039"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 348 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (1.1ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.319064"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.319064"]]  (0.8ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.332570"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.332570"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 350 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.339297"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.339297"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 351 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.342747"], ["state", "pending"], ["target_id", 351], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.342747"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 351) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:53.345710"], ["target_id", 351], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.345710"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 351 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.351831"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.351831"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 352 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.355447"], ["state", "pending"], ["target_id", 352], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.355447"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 352 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.360748"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.360748"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 353 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.364102"], ["state", "pending"], ["target_id", 353], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.364102"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 353) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:53.367015"], ["target_id", 353], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:51:53.367015"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 353 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 353 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.372762"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.372762"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 354 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.376157"], ["state", "pending"], ["target_id", 354], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.376157"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 354 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 354 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.382430"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.382430"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 355 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.386108"], ["state", "pending"], ["target_id", 355], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.386108"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 355) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.389141"], ["group_id", 1], ["target_id", 355], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.389141"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 355 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 355 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.396404"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.396404"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 356 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.400215"], ["state", "pending"], ["target_id", 356], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.400215"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 356) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:53.403117"], ["target_id", 356], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.403117"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 356 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 356 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.410173"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.410173"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 357 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.413427"], ["state", "pending"], ["target_id", 357], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.413427"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 357 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 357 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 455 [["group_id", 1], ["updated_at", "2015-09-07 00:51:53.417626"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 357 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 357 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.424352"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.424352"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 358 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.427704"], ["state", "pending"], ["target_id", 358], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.427704"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 456]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 358]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 358 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 358 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.436011"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.436011"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 359 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.439635"], ["state", "pending"], ["target_id", 359], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.439635"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 359) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:53.442645"], ["target_id", 359], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:51:53.442645"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 457]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 359]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 359 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 359 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.450925"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.450925"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 360 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.454809"], ["state", "pending"], ["target_id", 360], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.454809"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 360) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.457874"], ["group_id", 1], ["target_id", 360], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.457874"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 360 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 458]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 360]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 360 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.467749"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.467749"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 361 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.471273"], ["state", "pending"], ["target_id", 361], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.471273"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 361 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 361 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.478231"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.478231"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 362 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.481754"], ["state", "pending"], ["target_id", 362], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.481754"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 362) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:53.485528"], ["target_id", 362], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:51:53.485528"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 362 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 362 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.492628"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.492628"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 363 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.495895"], ["state", "pending"], ["target_id", 363], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.495895"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.6ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 363) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.500154"], ["group_id", 1], ["target_id", 363], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.500154"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 363 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 363 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.508055"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.508055"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 364 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.511568"], ["state", "pending"], ["target_id", 364], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.511568"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 364 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'OsBMbakZyOtZxHbmfK4sww0dwrzvAnqdq_NgkKLMcRFQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.515182"], ["target_id", 364], ["target_type", "User"], ["token", "OsBMbakZyOtZxHbmfK4sww0dwrzvAnqdq_NgkKLMcRFQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.515182"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.520698"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.520698"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 365 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.524375"], ["state", "pending"], ["target_id", 365], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.524375"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 365 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '4dLqFKfyH8nMj62cFcAAWw_o05tlBtZR29OifRmu1whg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.528046"], ["target_id", 365], ["target_type", "User"], ["token", "4dLqFKfyH8nMj62cFcAAWw_o05tlBtZR29OifRmu1whg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.528046"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 365 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.535576"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.535576"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 366 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.539047"], ["state", "pending"], ["target_id", 366], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.539047"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 366 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'qJXryukhJSlhaqhqvpHjDg2oLORg6g608mne5BLh4oWw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.542270"], ["target_id", 366], ["target_type", "User"], ["token", "qJXryukhJSlhaqhqvpHjDg2oLORg6g608mne5BLh4oWw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.542270"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 47 [["active", "f"], ["updated_at", "2015-09-07 00:51:53.544767"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 366 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.9ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'qRXGuMP9YcX4zAMx1c6togopqxhGjDGY0BNkla4nDTdg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.547633"], ["target_id", 366], ["target_type", "User"], ["token", "qRXGuMP9YcX4zAMx1c6togopqxhGjDGY0BNkla4nDTdg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.547633"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.554496"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.554496"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 367 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 367) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:53.558387"], ["target_id", 367], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.558387"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.561819"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.561819"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 368 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 368) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:53.565674"], ["target_id", 368], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.565674"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 368 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.571713"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.571713"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 369) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:53.574737"], ["target_id", 369], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.574737"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 369 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 79]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.581402"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.581402"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 370) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:53.584325"], ["target_id", 370], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-07 00:51:53.584325"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 370 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.590029"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.590029"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 371) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.593251"], ["group_id", 1], ["target_id", 371], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.593251"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 371 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 81]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.600512"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.600512"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 372) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.603784"], ["group_id", 1], ["target_id", 372], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.603784"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 372 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.609732"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.609732"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 373) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:53.612595"], ["target_id", 373], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.612595"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 373 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.617766"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.617766"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 374) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:53.620969"], ["target_id", 374], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.620969"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 374 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.626898"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.626898"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 375) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:51:53.629673"], ["target_id", 375], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.629673"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.6ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 375) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 375 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 375 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 85]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 375 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.640958"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.640958"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 376 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.645490"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.645490"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'mvwtCC7QTov4RWq3UndfUAh9kpeUW1pTBqBN296DmHQA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.647527"], ["target_id", 377], ["target_type", "User"], ["token", "mvwtCC7QTov4RWq3UndfUAh9kpeUW1pTBqBN296DmHQA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.647527"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.3ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'mvwtCC7QTov4RWq3UndfUAh9kpeUW1pTBqBN296DmHQA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.654982"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.654982"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '8hHApuduEweKe8i5iyrchgN_NbrVMroEtudwsKaueXJg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.656763"], ["target_id", 378], ["target_type", "User"], ["token", "8hHApuduEweKe8i5iyrchgN_NbrVMroEtudwsKaueXJg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.656763"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 50 [["active", "f"], ["updated_at", "2015-09-07 00:51:53.659916"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '8hHApuduEweKe8i5iyrchgN_NbrVMroEtudwsKaueXJg' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.664343"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.664343"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'LWjsI7S3UmdPr1DsgghWuAajZjMyXEc2JuroNM5R5fIw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.666340"], ["target_id", 379], ["target_type", "User"], ["token", "LWjsI7S3UmdPr1DsgghWuAajZjMyXEc2JuroNM5R5fIw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.666340"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 51 [["active", "f"], ["updated_at", "2015-09-07 00:51:53.669652"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:51:53.672586"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:51:53.672586"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'vUgcu4DvElQthBGa7RaKSwZcNfphrwCSa8j6Mbszr-nQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:51:53.674435"], ["target_id", 380], ["target_type", "User"], ["token", "vUgcu4DvElQthBGa7RaKSwZcNfphrwCSa8j6Mbszr-nQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:51:53.674435"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:54:44.964015"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:54:44.964015"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.2ms) Completed 200 OK in 17ms (Views: 13.3ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:54:44.996725"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:54:44.996725"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 382 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:54:45.021912"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 382], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:54:45.021912"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 382 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 382 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 75417ms  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:06.554433"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:06.554433"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.3ms) Completed 200 OK in 21ms (Views: 17.0ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:06.590351"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:06.590351"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 384 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.625509"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 384], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.625509"]]  (0.4ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 384 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 384 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 13ms  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:06.650614"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:06.650614"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 385 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.657723"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 385], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.657723"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 385 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 385 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:06.673646"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:06.673646"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 386 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.680046"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 386], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.680046"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 386 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.684226"], ["parent_id", 1], ["state", "pending"], ["target_id", 386], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.684226"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 386 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 386 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 7ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:06.706073"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:06.706073"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 387 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.715960"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 387], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.715960"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 387 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.721229"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 387], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.721229"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 387 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.726583"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 387], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.726583"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 387 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 145ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:06.890572"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:06.890572"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 388 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.899420"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 388], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.899420"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 388 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.902873"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 388], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.902873"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 388 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.906157"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 388], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.906157"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"473"} NotifyUser::BaseNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 388 AND "notify_user_notifications"."target_type" = 'User' AND (id = '473') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 388]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 388 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 473 [["state", "read"], ["updated_at", "2015-09-07 00:56:06.917210"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 12ms (Views: 1.3ms | ActiveRecord: 1.8ms) NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 473 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:06.928469"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:06.928469"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 389 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.934910"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 389], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.934910"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 389 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.956161"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 389], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.956161"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 389 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.959969"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 389], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.959969"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"476"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 389 AND "notify_user_notifications"."target_type" = 'User' AND (id = '476') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 389]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 389 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 476 [["state", "read"], ["updated_at", "2015-09-07 00:56:06.969770"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.3ms | ActiveRecord: 1.8ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"476"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 389 AND "notify_user_notifications"."target_type" = 'User' AND (id = '476') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.2ms | ActiveRecord: 2.2ms)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:06.981064"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:06.981064"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 390 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.987512"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 390], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.987512"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 390 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.991398"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 390], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.991398"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 390 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:06.994957"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 390], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:06.994957"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 390 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 390 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 4ms (Views: 0.9ms | ActiveRecord: 0.9ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 390 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.008955"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.008955"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 3ms (Views: 1.9ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.025494"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.025494"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 3ms (Views: 1.7ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.040140"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.040140"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 393 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.046808"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 393], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.046808"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["482"]} SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 393 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('482')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 393 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('482')) Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.062164"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.062164"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 394 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.074811"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 394], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.074811"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["483"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 394 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('483')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 394 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('483')) Completed 500 Internal Server Error in 6ms  (0.5ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.095672"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.095672"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 395 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.120439"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 395], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.120439"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 395 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 395 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 395) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:07.144142"], ["target_id", 395], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.144142"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 395 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 23ms (Views: 2.4ms | ActiveRecord: 2.0ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 395 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.8ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.161376"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.161376"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 396 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.172138"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 396], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.172138"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.8ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 396 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 396 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 396 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 11ms (Views: 3.8ms | ActiveRecord: 0.8ms) NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 396 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.198109"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.198109"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 397 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.205025"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 397], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.205025"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 397 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 397) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:07.213493"], ["target_id", 397], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.213493"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 397 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 8ms (ActiveRecord: 1.7ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.225963"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.225963"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 398 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.233776"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 398], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.233776"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 398) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:07.238050"], ["target_id", 398], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.238050"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 398 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 88]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 4ms (ActiveRecord: 1.0ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.251254"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.251254"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.263476"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 399], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.263476"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 399 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'C8-LWdmoSXv5Xmh24va5rQmrtF-KcWnUQHvVG8tBQwrQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.273296"], ["target_id", 399], ["target_type", "User"], ["token", "C8-LWdmoSXv5Xmh24va5rQmrtF-KcWnUQHvVG8tBQwrQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.273296"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"C8-LWdmoSXv5Xmh24va5rQmrtF-KcWnUQHvVG8tBQwrQ"} NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'C8-LWdmoSXv5Xmh24va5rQmrtF-KcWnUQHvVG8tBQwrQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'C8-LWdmoSXv5Xmh24va5rQmrtF-KcWnUQHvVG8tBQwrQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 399]]  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 399) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:07.283282"], ["target_id", 399], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.283282"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (1.0ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 53 [["active", "f"], ["updated_at", "2015-09-07 00:56:07.285028"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 10ms (Views: 0.3ms | ActiveRecord: 3.2ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (2.0ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.9ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 178.8ms NotifyUser::UserHash Load (0.7ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.7ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.1ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.512529"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.512529"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 400 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.516343"], ["state", "pending"], ["target_id", 400], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.516343"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.521650"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.521650"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 401 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.525594"], ["state", "pending"], ["target_id", 401], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.525594"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.530162"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.530162"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 402 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.534428"], ["state", "pending"], ["target_id", 402], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.534428"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.538890"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.538890"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 403 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.542753"], ["state", "pending"], ["target_id", 403], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.542753"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.548190"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.548190"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 404 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.551713"], ["state", "pending"], ["target_id", 404], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.551713"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 404 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.557760"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.557760"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 405 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.561302"], ["state", "pending"], ["target_id", 405], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.561302"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.565484"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.565484"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 406 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.569122"], ["state", "pending"], ["target_id", 406], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.569122"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.574164"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.574164"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 407 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.577492"], ["state", "pending"], ["target_id", 407], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.577492"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 407 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 496 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:56:07.580594"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.585952"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.585952"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 408 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.589340"], ["state", "pending"], ["target_id", 408], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.589340"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 408 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 497 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:56:07.592747"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.598190"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.598190"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 409 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.601454"], ["state", "pending"], ["target_id", 409], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.601454"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 409 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 498 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:56:07.604702"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.610880"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.610880"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.615414"], ["state", "pending"], ["target_id", 410], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.615414"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 499 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 00:56:07.618883"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.624203"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.624203"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.628355"], ["state", "pending"], ["target_id", 411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.628355"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.634401"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.634401"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.637551"], ["state", "pending"], ["target_id", 412], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.637551"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 501 [["state", "sent"], ["updated_at", "2015-09-07 00:56:07.642418"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 501 [["sent_time", "2015-09-07 00:56:07.643705"], ["updated_at", "2015-09-07 00:56:07.645164"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.649874"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.649874"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.653562"], ["state", "pending"], ["target_id", 413], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.653562"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 413 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 502)  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 502 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:07.660828"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 502]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 413]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 413 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 413]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 502 [["sent_time", "2015-09-07 00:56:07.667570"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:07.670289"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 502]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 413]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 413 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'SLe72PB69_-e7q4Mu5jtbgKz4X_X0h2U-y3FF-S7Dj0A' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.681119"], ["target_id", 413], ["target_type", "User"], ["token", "SLe72PB69_-e7q4Mu5jtbgKz4X_X0h2U-y3FF-S7Dj0A"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.681119"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.7ms Sent mail to user@example.com (3.7ms) Date: Mon, 07 Sep 2015 10:56:07 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ece0a7a772b_f0d13fe77c8601fc2681e@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.690734"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.690734"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 414 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.694910"], ["state", "pending_as_aggregation_parent"], ["target_id", 414], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.694910"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 414 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.699997"], ["state", "pending"], ["target_id", 414], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.699997"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 414 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 414 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 504)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.707674"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.707674"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.711149"], ["state", "pending"], ["target_id", 415], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.711149"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 505 [["state", "sent"], ["updated_at", "2015-09-07 00:56:07.715783"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 505 [["sent_time", "2015-09-07 00:56:07.716983"], ["updated_at", "2015-09-07 00:56:07.718722"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 505]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 415]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 415 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'GeFHGo0wmYeM53h3hQasDwNySUamNFamSNwwA-eF60EQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.728856"], ["target_id", 415], ["target_type", "User"], ["token", "GeFHGo0wmYeM53h3hQasDwNySUamNFamSNwwA-eF60EQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.728856"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 7.2ms Sent mail to user@example.com (9.7ms) Date: Mon, 07 Sep 2015 10:56:07 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ece0a7b44fb_f0d13fe77c8601fc2699c@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.747172"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.747172"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 416 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.751107"], ["state", "pending"], ["target_id", 416], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.751107"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 416 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 506 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-07 00:56:07.754255"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.758613"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.758613"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 417 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.762524"], ["state", "pending"], ["target_id", 417], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.762524"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 417) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:07.766810"], ["target_id", 417], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:56:07.766810"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 507]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 417]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 417 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 417 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.775147"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.775147"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.778948"], ["state", "pending"], ["target_id", 418], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.778948"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 508]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 418]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.787662"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.787662"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 419 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.791151"], ["state", "pending"], ["target_id", 419], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.791151"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 419 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 419 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 509 [["state", "sent"], ["updated_at", "2015-09-07 00:56:07.795721"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 419 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 509 [["sent_time", "2015-09-07 00:56:07.796949"], ["updated_at", "2015-09-07 00:56:07.798499"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 509]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 419]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 419 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 419 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 419 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'U7C8sh7ddSmrj-2A0JZBYAaXglwT8kSVYbIHvEeWUOYw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.809309"], ["target_id", 419], ["target_type", "User"], ["token", "U7C8sh7ddSmrj-2A0JZBYAaXglwT8kSVYbIHvEeWUOYw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.809309"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.9ms Sent mail to user@example.com (1.8ms) Date: Mon, 07 Sep 2015 10:56:07 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ece0a7c6777_f0d13fe77c8601fc2701a@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.817421"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.817421"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 420 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.820910"], ["state", "pending"], ["target_id", 420], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.820910"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 510]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 420]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 420 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 420 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.829904"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.829904"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 421 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.833037"], ["state", "pending"], ["target_id", 421], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.833037"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 511]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 421]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 421 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 421]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 421 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 511 [["sent_time", "2015-09-07 00:56:07.837766"], ["state", "sent"], ["updated_at", "2015-09-07 00:56:07.840227"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 421 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.846373"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.846373"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 422 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.849986"], ["state", "pending"], ["target_id", 422], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.849986"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 422 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.855966"], ["state", "pending"], ["target_id", 422], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.855966"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 513]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 422]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 422 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 422]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 422 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 513 [["sent_time", "2015-09-07 00:56:07.861332"], ["state", "sent"], ["updated_at", "2015-09-07 00:56:07.864301"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 422]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 422 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 512 [["sent_time", "2015-09-07 00:56:07.866212"], ["state", "sent"], ["updated_at", "2015-09-07 00:56:07.868914"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 422 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 422 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.877294"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.877294"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 423 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.880522"], ["state", "read"], ["target_id", 423], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.880522"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 514]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 423]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 423 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.888306"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.888306"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 424 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 424 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.892919"], ["group_id", 2], ["state", "pending"], ["target_id", 424], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.892919"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 515]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 424]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 424 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 424]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 424 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 424 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 515 [["sent_time", "2015-09-07 00:56:07.898680"], ["state", "sent"], ["updated_at", "2015-09-07 00:56:07.903063"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 424 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 424 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 515]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 424]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 424 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 424 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 424 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 424 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'QhAza3mAVD6o8_ZO-djupwByCshbdqLMJtGD9j0mqbhA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:07.916303"], ["target_id", 424], ["target_type", "User"], ["token", "QhAza3mAVD6o8_ZO-djupwByCshbdqLMJtGD9j0mqbhA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.916303"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.9ms Sent mail to user@example.com (2.5ms) Date: Mon, 07 Sep 2015 10:56:07 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ece0a7e0a98_f0d13fe77c8601fc2714f@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.925177"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.925177"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 425 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 425 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.930253"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 425], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.930253"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 425 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 425 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 516 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:07.934503"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 425 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 425 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 516 [["sent_time", "2015-09-07 00:56:07.935771"], ["updated_at", "2015-09-07 00:56:07.938330"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 516]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.946470"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.946470"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 426 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 426 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.951031"], ["group_id", 1], ["state", "pending"], ["target_id", 426], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.951031"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 426 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 517) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.957139"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.957139"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 427 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 427 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.962577"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 427], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.962577"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 427 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 427 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.968605"], ["group_id", 1], ["state", "pending"], ["target_id", 427], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.968605"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 427 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 519) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.974296"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.974296"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 428 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 428 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.979160"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 428], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.979160"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 428 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 428 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.983477"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 428], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.983477"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 428 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 428 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.987747"], ["group_id", 1], ["state", "pending"], ["target_id", 428], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.987747"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 428 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 522) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:07.994147"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:07.994147"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 429 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 429 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:07.998707"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 429], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:07.998707"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 429 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 429 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.003185"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 429], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.003185"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 429 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 429 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.007757"], ["group_id", 1], ["state", "pending"], ["target_id", 429], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.007757"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 429 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 525) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.014665"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.014665"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 430 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 430 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.019238"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 430], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.019238"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 430 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 430 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.023928"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 430], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.023928"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 430 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 430 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.028427"], ["group_id", 1], ["state", "pending"], ["target_id", 430], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.028427"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 430 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 528) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.034715"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.034715"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 431 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 431 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 14:56:08.035898"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 431], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.039321"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 431 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:56:08.041219') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 431 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:56:08.041219') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 431 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 431 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 00:56:08.047127"], ["group_id", 1], ["parent_id", 529], ["state", "pending"], ["target_id", 431], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.047127"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.051674"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.051674"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 432 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 432 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-05 23:56:08.053146"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 432], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.057643"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 432 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:56:08.060417')  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 432 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 432 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.066720"], ["group_id", 1], ["state", "pending"], ["target_id", 432], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.066720"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.072734"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.072734"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 433 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 433 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-05 23:56:08.074169"], ["group_id", 1], ["state", "pending"], ["target_id", 433], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.078572"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 433 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:56:08.082601')  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 433 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 433 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.089376"], ["group_id", 1], ["state", "pending"], ["target_id", 433], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.089376"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.7ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.096891"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.096891"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 434 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 434 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.104167"], ["group_id", 1], ["state", "pending"], ["target_id", 434], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.104167"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 434 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 535) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 434 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 535) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.112985"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.112985"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 435 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 435 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.119332"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 435], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.119332"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 435 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 435 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 536 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.134568"]]  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 435 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 435 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 536 [["sent_time", "2015-09-07 00:56:08.135890"], ["updated_at", "2015-09-07 00:56:08.141925"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 435 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 435 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.148281"], ["group_id", 1], ["state", "pending"], ["target_id", 435], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.148281"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 435 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 537) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 435 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 537) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.157266"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.157266"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.162166"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 436], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.162166"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 538 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.167095"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 538 [["sent_time", "2015-09-07 00:56:08.168341"], ["updated_at", "2015-09-07 00:56:08.171156"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.176224"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 436], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.176224"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 539 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.180746"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 539 [["sent_time", "2015-09-07 00:56:08.182016"], ["updated_at", "2015-09-07 00:56:08.184960"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.190300"], ["group_id", 1], ["state", "pending"], ["target_id", 436], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.190300"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 436 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 540) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 436 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 540) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.199885"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.199885"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.204946"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 437], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.204946"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 541 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.209621"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 541 [["sent_time", "2015-09-07 00:56:08.211007"], ["updated_at", "2015-09-07 00:56:08.214011"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.219115"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 437], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.219115"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 542 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.223789"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 542 [["sent_time", "2015-09-07 00:56:08.225273"], ["updated_at", "2015-09-07 00:56:08.227989"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.233321"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 437], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.233321"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 543 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.238591"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 543 [["sent_time", "2015-09-07 00:56:08.239998"], ["updated_at", "2015-09-07 00:56:08.242883"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.247609"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 437], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.247609"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 544 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.252273"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 544 [["sent_time", "2015-09-07 00:56:08.253691"], ["updated_at", "2015-09-07 00:56:08.256748"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.261475"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 437], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.261475"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 545 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.265815"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 545 [["sent_time", "2015-09-07 00:56:08.266961"], ["updated_at", "2015-09-07 00:56:08.269647"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.274576"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 437], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.274576"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 546 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.279567"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 546 [["sent_time", "2015-09-07 00:56:08.280941"], ["updated_at", "2015-09-07 00:56:08.283610"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.288623"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 437], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.288623"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 547 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.293403"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 547 [["sent_time", "2015-09-07 00:56:08.294924"], ["updated_at", "2015-09-07 00:56:08.298066"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.303334"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 437], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.303334"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 548 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.307950"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 548 [["sent_time", "2015-09-07 00:56:08.309273"], ["updated_at", "2015-09-07 00:56:08.312704"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (1.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.325700"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 437], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.325700"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 549 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.330968"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 549 [["sent_time", "2015-09-07 00:56:08.332383"], ["updated_at", "2015-09-07 00:56:08.335031"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.340237"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 437], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.340237"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 550 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.344660"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 550 [["sent_time", "2015-09-07 00:56:08.346043"], ["updated_at", "2015-09-07 00:56:08.349058"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.354061"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 437], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.354061"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 551 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.359423"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 551 [["sent_time", "2015-09-07 00:56:08.360736"], ["updated_at", "2015-09-07 00:56:08.363722"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.368872"], ["group_id", 1], ["state", "pending"], ["target_id", 437], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.368872"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 437 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 552) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 437 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 552) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.377636"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.377636"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 438 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 438 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.382780"], ["group_id", 1], ["state", "pending"], ["target_id", 438], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.382780"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 438 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 438 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 438 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 553)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 438 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 438 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 553 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.393704"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.398640"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.398640"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 439 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 439 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.403288"], ["group_id", 1], ["state", "pending"], ["target_id", 439], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.403288"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 439 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 439 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 439 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 554)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 439 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 439 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 554 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.412486"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.418236"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.418236"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 440 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 440 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.423322"], ["group_id", 1], ["state", "pending"], ["target_id", 440], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.423322"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 440 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 440 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 440 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 555)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 440 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 440 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 555 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.431923"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 555]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.437733"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.437733"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 441 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 441 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.442686"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 441], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.442686"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 441 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 441 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:58:08.442686"], ["group_id", 1], ["state", "pending"], ["target_id", 441], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.447212"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 441 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 441 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 441 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 557)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 441 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 441 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 557 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 00:56:08.457276"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.462379"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.462379"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 442 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 442 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.466927"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 442], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.466927"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 442 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:56:08.468955') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 442 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 00:56:08.468955') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 442 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 442 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 00:58:08.466927"], ["group_id", 1], ["parent_id", 558], ["state", "pending"], ["target_id", 442], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.474309"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 559]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.480008"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.480008"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 443 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 443 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.484537"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 443], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.484537"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 443 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 443 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.489224"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 443], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.489224"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 443 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 443 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.494017"], ["group_id", 1], ["state", "pending"], ["target_id", 443], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.494017"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 443 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 443 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 443 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 562)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.503211"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.503211"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 444 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 444 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.508864"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 444], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.508864"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 444 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 444 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.513827"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 444], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.513827"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 444 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 444 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:56:08.518352"], ["group_id", 1], ["state", "pending"], ["target_id", 444], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.518352"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 444 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 444 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 444 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 565) NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 565]]  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.533629"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.533629"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 445 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.540576"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.540576"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 446 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 446 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.548642"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.548642"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 447 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.555001"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.555001"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 448 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.558837"], ["state", "pending"], ["target_id", 448], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.558837"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 448) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:08.562032"], ["target_id", 448], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.562032"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 448 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.567808"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.567808"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 449 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.571353"], ["state", "pending"], ["target_id", 449], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.571353"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 449 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.576701"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.576701"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 450 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.580209"], ["state", "pending"], ["target_id", 450], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.580209"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 450) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:08.583411"], ["target_id", 450], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:56:08.583411"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 450 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 450 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.590659"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.590659"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 451 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.594498"], ["state", "pending"], ["target_id", 451], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.594498"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 451 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 451 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.600935"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.600935"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 452 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.604686"], ["state", "pending"], ["target_id", 452], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.604686"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 452) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.607700"], ["group_id", 1], ["target_id", 452], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.607700"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 452 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 452 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.614900"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.614900"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 453 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.618312"], ["state", "pending"], ["target_id", 453], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.618312"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 453) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:08.621408"], ["target_id", 453], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.621408"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 453 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 453 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.629044"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.629044"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 454 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.633351"], ["state", "pending"], ["target_id", 454], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.633351"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 454 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 454 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 572 [["group_id", 1], ["updated_at", "2015-09-07 00:56:08.637626"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 454 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 454 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.644279"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.644279"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 455 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.647548"], ["state", "pending"], ["target_id", 455], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.647548"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 573]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 455]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 455 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 455 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.656079"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.656079"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 456 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.659488"], ["state", "pending"], ["target_id", 456], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.659488"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 456) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:08.662396"], ["target_id", 456], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:56:08.662396"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 574]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 456]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 456 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 456 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.670354"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.670354"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 457 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.674806"], ["state", "pending"], ["target_id", 457], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.674806"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 457) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.677840"], ["group_id", 1], ["target_id", 457], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.677840"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 457 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 575]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 457]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 457 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.687544"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.687544"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 458 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.691113"], ["state", "pending"], ["target_id", 458], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.691113"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 458 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 458 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.697603"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.697603"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 459 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.701403"], ["state", "pending"], ["target_id", 459], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.701403"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 459) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:08.704752"], ["target_id", 459], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 00:56:08.704752"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 459 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 459 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.711449"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.711449"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 460 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.715683"], ["state", "pending"], ["target_id", 460], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.715683"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 460) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.718869"], ["group_id", 1], ["target_id", 460], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.718869"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 460 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 460 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.726360"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.726360"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 461 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.730117"], ["state", "pending"], ["target_id", 461], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.730117"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (1.9ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 461 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (1.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'u19UOr0xcHhakteyaZNT0w8F6asKSexema8Z194JiYRA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.740718"], ["target_id", 461], ["target_type", "User"], ["token", "u19UOr0xcHhakteyaZNT0w8F6asKSexema8Z194JiYRA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.740718"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.746152"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.746152"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 462 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.749492"], ["state", "pending"], ["target_id", 462], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.749492"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 462 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.5ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'UXx4uIbDX2RQCweCks58KQAnpGUMgjVnX6TuqBHSXAmQ' LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.753481"], ["target_id", 462], ["target_type", "User"], ["token", "UXx4uIbDX2RQCweCks58KQAnpGUMgjVnX6TuqBHSXAmQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.753481"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 462 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.760837"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.760837"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 463 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.764454"], ["state", "pending"], ["target_id", 463], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.764454"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 463 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'bGJwyBe9xOogSZ_MUh91Ow-LXfoGUOMNol-ExXI6qeNQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.767974"], ["target_id", 463], ["target_type", "User"], ["token", "bGJwyBe9xOogSZ_MUh91Ow-LXfoGUOMNol-ExXI6qeNQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.767974"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 60 [["active", "f"], ["updated_at", "2015-09-07 00:56:08.770358"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 463 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'AVLhlKIHF9LegANLHlkh7AIx4R0fyeEERUAlZCTRbVGg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.773373"], ["target_id", 463], ["target_type", "User"], ["token", "AVLhlKIHF9LegANLHlkh7AIx4R0fyeEERUAlZCTRbVGg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.773373"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.778635"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.778635"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 464 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 464) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:08.782788"], ["target_id", 464], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.782788"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.786331"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.786331"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 465 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 465) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:08.790459"], ["target_id", 465], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.790459"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 465 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.796552"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.796552"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 466) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:08.800551"], ["target_id", 466], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.800551"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 466 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 101]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.807099"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.807099"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 467) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:08.809908"], ["target_id", 467], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-07 00:56:08.809908"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 467 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.815427"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.815427"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 468) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.818201"], ["group_id", 1], ["target_id", 468], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.818201"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 468 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 103]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.825162"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.825162"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 469) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.828041"], ["group_id", 1], ["target_id", 469], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.828041"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 469 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.833584"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.833584"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 470) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:08.836408"], ["target_id", 470], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.836408"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 470 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.842599"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.842599"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 471) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:08.845501"], ["target_id", 471], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.845501"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 471 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.851177"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.851177"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 472) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 00:56:08.853949"], ["target_id", 472], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.853949"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 472) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 472 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 472 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 107]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 472 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.864611"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.864611"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 473 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.869234"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.869234"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'tgciDTPLBCcleaZIHqejbAGdD_9nVKbVN9h_7ALkSKHg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.871108"], ["target_id", 474], ["target_type", "User"], ["token", "tgciDTPLBCcleaZIHqejbAGdD_9nVKbVN9h_7ALkSKHg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.871108"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'tgciDTPLBCcleaZIHqejbAGdD_9nVKbVN9h_7ALkSKHg' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.877222"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.877222"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'uM3lX3cjFrAz0z5-3XcU2wwAw_2BFNgn6GgQmpfeCNxQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.879182"], ["target_id", 475], ["target_type", "User"], ["token", "uM3lX3cjFrAz0z5-3XcU2wwAw_2BFNgn6GgQmpfeCNxQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.879182"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 63 [["active", "f"], ["updated_at", "2015-09-07 00:56:08.883575"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'uM3lX3cjFrAz0z5-3XcU2wwAw_2BFNgn6GgQmpfeCNxQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.887443"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.887443"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'JqaNymzUrj2IE5cbRtHyywViwXE-8xbpoZzqzOR-LiAg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.889416"], ["target_id", 476], ["target_type", "User"], ["token", "JqaNymzUrj2IE5cbRtHyywViwXE-8xbpoZzqzOR-LiAg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.889416"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 64 [["active", "f"], ["updated_at", "2015-09-07 00:56:08.892847"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 00:56:08.895860"], ["email", "user@example.com"], ["updated_at", "2015-09-07 00:56:08.895860"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ne7Wr_sqysmkALr5YTOwhgNWyiJKYSIPyOFZmk9dIb7w' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 00:56:08.897667"], ["target_id", 477], ["target_type", "User"], ["token", "ne7Wr_sqysmkALr5YTOwhgNWyiJKYSIPyOFZmk9dIb7w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 00:56:08.897667"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.024619"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.024619"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.2ms) Completed 200 OK in 17ms (Views: 13.7ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.057351"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.057351"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 479 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.084873"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 479], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.084873"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 479 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 479 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 13ms  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.107997"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.107997"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 480 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.114147"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 480], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.114147"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 480 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 480 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.127553"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.127553"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 481 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.133215"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 481], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.133215"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 481 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.136601"], ["parent_id", 1], ["state", "pending"], ["target_id", 481], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.136601"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 481 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 481 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 7ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.151921"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.151921"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 482 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.157726"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 482], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.157726"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 482 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.161432"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 482], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.161432"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 482 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.164877"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 482], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.164877"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 482 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 143ms  (0.3ms) ROLLBACK  (0.6ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.318545"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.318545"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 483 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.324853"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 483], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.324853"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 483 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.328577"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 483], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.328577"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 483 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.333271"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 483], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.333271"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"589"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 483 AND "notify_user_notifications"."target_type" = 'User' AND (id = '589') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 483]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 483 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 589 [["state", "read"], ["updated_at", "2015-09-07 01:01:25.355453"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 22ms (Views: 1.6ms | ActiveRecord: 1.8ms) NotifyUser::BaseNotification Load (0.9ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 589 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.372767"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.372767"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 484 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.380605"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 484], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.380605"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 484 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.384968"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 484], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.384968"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 484 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.388956"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 484], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.388956"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"592"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 484 AND "notify_user_notifications"."target_type" = 'User' AND (id = '592') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 484]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 484 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 592 [["state", "read"], ["updated_at", "2015-09-07 01:01:25.398810"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.3ms | ActiveRecord: 1.6ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"592"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 484 AND "notify_user_notifications"."target_type" = 'User' AND (id = '592') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 3ms (Views: 0.2ms | ActiveRecord: 2.1ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.410675"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.410675"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 485 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.423083"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 485], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.423083"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 485 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.426972"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 485], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.426972"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 485 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.430734"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 485], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.430734"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 485 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 485 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 4ms (Views: 0.8ms | ActiveRecord: 0.9ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 485 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.444535"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.444535"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 3ms (Views: 1.7ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.462582"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.462582"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 3ms (Views: 1.7ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.477606"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.477606"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 488 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.484880"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 488], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.484880"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["598"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 488 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('598')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 488 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('598')) Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.502620"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.502620"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 489 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.515991"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 489], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.515991"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["599"]} SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 489 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('599')) NotifyUser::BaseNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 489 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('599')) Completed 500 Internal Server Error in 10ms  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.541414"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.541414"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 490 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.550262"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 490], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.550262"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 490 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.6ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 490 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 490) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:25.571354"], ["target_id", 490], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.571354"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 490 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 20ms (Views: 2.3ms | ActiveRecord: 2.0ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 490 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.584100"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.584100"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 491 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.590765"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 491], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.590765"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 491 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 491 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 491 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 8ms (Views: 2.4ms | ActiveRecord: 0.8ms) NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 491 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.611033"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.611033"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 492 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.617818"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 492], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.617818"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 492 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 492) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:25.633067"], ["target_id", 492], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.633067"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 492 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 15ms (ActiveRecord: 1.7ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.643573"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.643573"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 493 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.650332"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 493], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.650332"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 493) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:25.653483"], ["target_id", 493], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.653483"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 493 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 110]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 4ms (ActiveRecord: 0.9ms) NotifyUser::Unsubscribe Load (0.2ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.665502"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.665502"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 494 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:25.671819"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 494], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.671819"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 494 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ckHboUaXXIwzbAQYOhhu_ggP-idrw5QHNRopwxrlBERA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:25.682678"], ["target_id", 494], ["target_type", "User"], ["token", "ckHboUaXXIwzbAQYOhhu_ggP-idrw5QHNRopwxrlBERA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.682678"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"ckHboUaXXIwzbAQYOhhu_ggP-idrw5QHNRopwxrlBERA"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ckHboUaXXIwzbAQYOhhu_ggP-idrw5QHNRopwxrlBERA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ckHboUaXXIwzbAQYOhhu_ggP-idrw5QHNRopwxrlBERA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 494]]  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 494) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:25.691832"], ["target_id", 494], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.691832"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 66 [["active", "f"], ["updated_at", "2015-09-07 01:01:25.693726"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.3ms | ActiveRecord: 2.2ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 228.0ms NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.5ms NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.8ms NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.964615"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.964615"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 495 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:25.967906"], ["state", "pending"], ["target_id", 495], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.967906"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.973178"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.973178"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 496 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:25.977100"], ["state", "pending"], ["target_id", 496], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.977100"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.982165"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.982165"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 497 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:25.985431"], ["state", "pending"], ["target_id", 497], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.985431"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.989781"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.989781"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 498 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:25.993177"], ["state", "pending"], ["target_id", 498], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:25.993177"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:25.997654"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:25.997654"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 499 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.000835"], ["state", "pending"], ["target_id", 499], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.000835"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 499 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.006458"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.006458"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 500 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.009977"], ["state", "pending"], ["target_id", 500], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.009977"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.014022"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.014022"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 501 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.017471"], ["state", "pending"], ["target_id", 501], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.017471"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.021470"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.021470"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 502 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.024759"], ["state", "pending"], ["target_id", 502], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.024759"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 502 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 612 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 01:01:26.028548"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.033874"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.033874"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 503 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.037281"], ["state", "pending"], ["target_id", 503], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.037281"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 503 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 613 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 01:01:26.040309"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.045784"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.045784"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 504 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.048929"], ["state", "pending"], ["target_id", 504], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.048929"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 504 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 614 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 01:01:26.051675"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.056797"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.056797"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 505 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.060021"], ["state", "pending"], ["target_id", 505], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.060021"]]  (0.8ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 505 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 615 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 01:01:26.064332"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.069923"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.069923"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 506 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.073155"], ["state", "pending"], ["target_id", 506], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.073155"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 506 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.079911"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.079911"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 507 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.083020"], ["state", "pending"], ["target_id", 507], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.083020"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 507 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 507 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 617 [["state", "sent"], ["updated_at", "2015-09-07 01:01:26.087718"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 507 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 617 [["sent_time", "2015-09-07 01:01:26.089013"], ["updated_at", "2015-09-07 01:01:26.090558"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.095188"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.095188"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 508 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.098536"], ["state", "pending"], ["target_id", 508], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.098536"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 508 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 508 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 618)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 508 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 618 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.104910"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 618]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 508]] NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 508 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 508]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 508 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 618 [["sent_time", "2015-09-07 01:01:26.112151"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.115243"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 508 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 618]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 508]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 508 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 508 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 508 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '_CTICTEIj5YYJIp-iJjcyAL7M6V5-KZk8BfCMeChrJ3g' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.126746"], ["target_id", 508], ["target_type", "User"], ["token", "_CTICTEIj5YYJIp-iJjcyAL7M6V5-KZk8BfCMeChrJ3g"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.126746"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 7.7ms Sent mail to user@example.com (3.2ms) Date: Mon, 07 Sep 2015 11:01:26 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ece1e620459_f48e3fd9e9060204966fd@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.136865"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.136865"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 509 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.140027"], ["state", "pending_as_aggregation_parent"], ["target_id", 509], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.140027"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 509 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.143864"], ["state", "pending"], ["target_id", 509], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.143864"]]  (0.8ms) RELEASE SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 509 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 509 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 620)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.158088"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.158088"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.162778"], ["state", "pending"], ["target_id", 510], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.162778"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 621 [["state", "sent"], ["updated_at", "2015-09-07 01:01:26.167171"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 621 [["sent_time", "2015-09-07 01:01:26.168309"], ["updated_at", "2015-09-07 01:01:26.169955"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 621]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 510]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 510 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'nrtnOc82YeVQXyGU_esBEQezrf0PI8QF50wdYmgXznEA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.180305"], ["target_id", 510], ["target_type", "User"], ["token", "nrtnOc82YeVQXyGU_esBEQezrf0PI8QF50wdYmgXznEA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.180305"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.6ms Sent mail to user@example.com (1.6ms) Date: Mon, 07 Sep 2015 11:01:26 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ece1e62ce69_f48e3fd9e9060204967b8@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.188451"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.188451"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.192083"], ["state", "pending"], ["target_id", 511], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.192083"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 622 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-07 01:01:26.195367"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.199459"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.199459"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.202636"], ["state", "pending"], ["target_id", 512], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.202636"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 512) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:26.205822"], ["target_id", 512], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 01:01:26.205822"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 623]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 512]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.214092"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.214092"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 513 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.217499"], ["state", "pending"], ["target_id", 513], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.217499"]]  (0.8ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 624]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 513]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 513 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 513 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.228445"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.228445"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.231968"], ["state", "pending"], ["target_id", 514], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.231968"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 625 [["state", "sent"], ["updated_at", "2015-09-07 01:01:26.236748"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 625 [["sent_time", "2015-09-07 01:01:26.238006"], ["updated_at", "2015-09-07 01:01:26.239584"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 625]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 514]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 514 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '8_YCdxWNJnXjYvTVOslx6wun5F2b62OY90zV-taFxH2Q' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.248279"], ["target_id", 514], ["target_type", "User"], ["token", "8_YCdxWNJnXjYvTVOslx6wun5F2b62OY90zV-taFxH2Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.248279"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.5ms Sent mail to user@example.com (1.7ms) Date: Mon, 07 Sep 2015 11:01:26 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ece1e63d7dc_f48e3fd9e906020496869@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.255889"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.255889"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 515 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.259595"], ["state", "pending"], ["target_id", 515], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.259595"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 626]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 515]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 515 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 515 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.268835"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.268835"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.271938"], ["state", "pending"], ["target_id", 516], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.271938"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 627]] User Load (0.7ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 516]] NewPostNotification Load (1.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 516 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.8ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 516]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 627 [["sent_time", "2015-09-07 01:01:26.282682"], ["state", "sent"], ["updated_at", "2015-09-07 01:01:26.287177"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.293676"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.293676"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 517 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.298556"], ["state", "pending"], ["target_id", 517], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.298556"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 517 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.302222"], ["state", "pending"], ["target_id", 517], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.302222"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 629]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 517]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 517 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 517]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 517 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 629 [["sent_time", "2015-09-07 01:01:26.306713"], ["state", "sent"], ["updated_at", "2015-09-07 01:01:26.309640"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 517]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 517 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 628 [["sent_time", "2015-09-07 01:01:26.311879"], ["state", "sent"], ["updated_at", "2015-09-07 01:01:26.315444"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 517 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 517 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.324122"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.324122"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 518 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.328310"], ["state", "read"], ["target_id", 518], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.328310"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 630]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 518]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 518 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.335914"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.335914"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.340166"], ["group_id", 2], ["state", "pending"], ["target_id", 519], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.340166"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.9ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 631]] User Load (1.0ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 519]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 519 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 519]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 631 [["sent_time", "2015-09-07 01:01:26.353690"], ["state", "sent"], ["updated_at", "2015-09-07 01:01:26.357597"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 631]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 519]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 519 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'id5SAwwMHa1xyWoCIqTL1API9Ei5zmfCWObxkV4tJA_A' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.370931"], ["target_id", 519], ["target_type", "User"], ["token", "id5SAwwMHa1xyWoCIqTL1API9Ei5zmfCWObxkV4tJA_A"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.370931"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.8ms Sent mail to user@example.com (2.0ms) Date: Mon, 07 Sep 2015 11:01:26 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ece1e65b785_f48e3fd9e9060204969ae@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.380142"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.380142"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 520 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 520 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.384292"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 520], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.384292"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 520 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 520 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 632 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.388580"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 520 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 520 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 632 [["sent_time", "2015-09-07 01:01:26.389811"], ["updated_at", "2015-09-07 01:01:26.392295"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 632]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.399252"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.399252"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 521 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 521 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.403651"], ["group_id", 1], ["state", "pending"], ["target_id", 521], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.403651"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 521 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 633) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.409447"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.409447"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 522 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 522 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.414002"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 522], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.414002"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 522 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 522 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.418288"], ["group_id", 1], ["state", "pending"], ["target_id", 522], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.418288"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 522 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 635) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.423967"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.423967"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 523 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 523 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.429157"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 523], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.429157"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 523 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 523 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.433515"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 523], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.433515"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 523 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 523 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.437853"], ["group_id", 1], ["state", "pending"], ["target_id", 523], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.437853"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 523 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 638) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.443660"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.443660"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 524 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 524 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.447786"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 524], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.447786"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 524 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 524 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.452444"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 524], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.452444"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 524 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 524 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.456895"], ["group_id", 1], ["state", "pending"], ["target_id", 524], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.456895"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 524 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 641) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.462815"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.462815"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.467254"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 525], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.467254"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.471778"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 525], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.471778"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.477300"], ["group_id", 1], ["state", "pending"], ["target_id", 525], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.477300"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 525 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 644) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.494938"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.494938"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 526 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 526 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 15:01:26.496234"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 526], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.499973"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 526 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 01:01:26.502862') NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 526 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 01:01:26.502862') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 526 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 526 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 01:01:26.512745"], ["group_id", 1], ["parent_id", 645], ["state", "pending"], ["target_id", 526], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.512745"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.520348"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.520348"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 527 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 527 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 00:01:26.522177"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 527], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.528416"]]  (1.1ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 527 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 01:01:26.533002')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 527 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 527 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.538275"], ["group_id", 1], ["state", "pending"], ["target_id", 527], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.538275"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.544380"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.544380"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 528 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 528 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 00:01:26.545749"], ["group_id", 1], ["state", "pending"], ["target_id", 528], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.549278"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 528 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 01:01:26.552219')  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 528 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 528 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.558275"], ["group_id", 1], ["state", "pending"], ["target_id", 528], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.558275"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.563226"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.563226"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 529 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 529 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.568194"], ["group_id", 1], ["state", "pending"], ["target_id", 529], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.568194"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 529 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 651) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 529 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 651) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.576666"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.576666"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.581447"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 530], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.581447"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 652 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.585647"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 652 [["sent_time", "2015-09-07 01:01:26.586917"], ["updated_at", "2015-09-07 01:01:26.589783"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.594765"], ["group_id", 1], ["state", "pending"], ["target_id", 530], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.594765"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 530 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 653) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 530 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 653) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.603030"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.603030"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.607706"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 531], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.607706"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 654 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.612431"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 654 [["sent_time", "2015-09-07 01:01:26.613704"], ["updated_at", "2015-09-07 01:01:26.616507"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.621440"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 531], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.621440"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.7ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 655 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.626626"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 655 [["sent_time", "2015-09-07 01:01:26.628406"], ["updated_at", "2015-09-07 01:01:26.631017"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.635653"], ["group_id", 1], ["state", "pending"], ["target_id", 531], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.635653"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 531 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 656) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 531 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 656) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.643993"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.643993"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.649251"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.649251"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 657 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.653653"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 657 [["sent_time", "2015-09-07 01:01:26.655016"], ["updated_at", "2015-09-07 01:01:26.657691"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.662501"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.662501"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 658 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.666962"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 658 [["sent_time", "2015-09-07 01:01:26.668203"], ["updated_at", "2015-09-07 01:01:26.671090"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.675909"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.675909"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 659 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.681227"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 659 [["sent_time", "2015-09-07 01:01:26.682528"], ["updated_at", "2015-09-07 01:01:26.685271"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.690821"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.690821"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 660 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.696432"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 660 [["sent_time", "2015-09-07 01:01:26.697765"], ["updated_at", "2015-09-07 01:01:26.700474"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.705447"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.705447"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 661 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.710111"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 661 [["sent_time", "2015-09-07 01:01:26.711489"], ["updated_at", "2015-09-07 01:01:26.714063"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.719312"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.719312"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 662 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.723538"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 662 [["sent_time", "2015-09-07 01:01:26.724838"], ["updated_at", "2015-09-07 01:01:26.727796"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.732314"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.732314"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 663 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.736167"]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 663 [["sent_time", "2015-09-07 01:01:26.737351"], ["updated_at", "2015-09-07 01:01:26.740225"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.0ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.748351"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.748351"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 664 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.755876"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 664 [["sent_time", "2015-09-07 01:01:26.757176"], ["updated_at", "2015-09-07 01:01:26.760209"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.766399"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.766399"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 665 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.770847"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 665 [["sent_time", "2015-09-07 01:01:26.772108"], ["updated_at", "2015-09-07 01:01:26.775246"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.779856"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.779856"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 666 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.784253"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 666 [["sent_time", "2015-09-07 01:01:26.785498"], ["updated_at", "2015-09-07 01:01:26.788109"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.792463"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.792463"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 667 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.796649"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 667 [["sent_time", "2015-09-07 01:01:26.797988"], ["updated_at", "2015-09-07 01:01:26.800787"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.805506"], ["group_id", 1], ["state", "pending"], ["target_id", 532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.805506"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 532 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 668) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 532 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 668) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.813459"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.813459"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 533 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 533 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.818246"], ["group_id", 1], ["state", "pending"], ["target_id", 533], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.818246"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 533 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 533 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 533 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 669)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 533 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 533 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 669 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.828885"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.833993"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.833993"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 534 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 534 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.838524"], ["group_id", 1], ["state", "pending"], ["target_id", 534], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.838524"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 534 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 534 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 534 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 670)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 534 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 534 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 670 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.847730"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.852402"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.852402"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 535 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 535 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.857043"], ["group_id", 1], ["state", "pending"], ["target_id", 535], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.857043"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 535 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 535 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 535 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 671)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 535 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 535 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 671 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.866166"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 671]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.873020"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.873020"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.877357"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 536], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.877357"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:03:26.877357"], ["group_id", 1], ["state", "pending"], ["target_id", 536], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.882011"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 536 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 673)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 673 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 01:01:26.890507"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.895384"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.895384"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.900260"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 537], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.900260"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 537 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 01:01:26.902706') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 537 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 01:01:26.902706') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 01:03:26.900260"], ["group_id", 1], ["parent_id", 674], ["state", "pending"], ["target_id", 537], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.908187"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 675]]  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.914250"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.914250"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.918572"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.918572"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.923077"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.923077"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.927555"], ["group_id", 1], ["state", "pending"], ["target_id", 538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.927555"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 538 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 678)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.936011"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.936011"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 539 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 539 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.940579"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 539], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.940579"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 539 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 539 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.944966"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 539], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.944966"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 539 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 539 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:01:26.949626"], ["group_id", 1], ["state", "pending"], ["target_id", 539], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.949626"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 539 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 539 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 539 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 681) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 681]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.958234"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.958234"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 540 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.964801"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.964801"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 541 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 541 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.971464"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.971464"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 542 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.977104"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.977104"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 543 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.980591"], ["state", "pending"], ["target_id", 543], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.980591"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 543) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:26.983833"], ["target_id", 543], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.983833"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 543 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.988632"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.988632"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 544 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:26.991930"], ["state", "pending"], ["target_id", 544], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:26.991930"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 544 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:26.997028"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:26.997028"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 545 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.001003"], ["state", "pending"], ["target_id", 545], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.001003"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 545) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:27.004024"], ["target_id", 545], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 01:01:27.004024"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 545 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 545 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.010597"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.010597"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 546 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.013804"], ["state", "pending"], ["target_id", 546], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.013804"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 546 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 546 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.019626"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.019626"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 547 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.022789"], ["state", "pending"], ["target_id", 547], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.022789"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 547) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.025621"], ["group_id", 1], ["target_id", 547], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.025621"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 547 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 547 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.032928"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.032928"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 548 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.036512"], ["state", "pending"], ["target_id", 548], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.036512"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 548) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:27.039505"], ["target_id", 548], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.039505"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 548 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 548 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.046443"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.046443"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 549 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.049685"], ["state", "pending"], ["target_id", 549], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.049685"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 549 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 549 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 688 [["group_id", 1], ["updated_at", "2015-09-07 01:01:27.053716"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 549 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 549 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.061118"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.061118"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 550 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.064449"], ["state", "pending"], ["target_id", 550], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.064449"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 689]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 550]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 550 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 550 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.072281"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.072281"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 551 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.075489"], ["state", "pending"], ["target_id", 551], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.075489"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 551) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:27.078496"], ["target_id", 551], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 01:01:27.078496"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 690]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 551]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 551 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 551 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.086070"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.086070"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 552 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.089470"], ["state", "pending"], ["target_id", 552], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.089470"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 552) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.092362"], ["group_id", 1], ["target_id", 552], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.092362"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 552 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 691]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 552]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 552 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.101504"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.101504"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 553 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.104764"], ["state", "pending"], ["target_id", 553], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.104764"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 553 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 553 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.111847"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.111847"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 554 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.115350"], ["state", "pending"], ["target_id", 554], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.115350"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 554) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:27.118246"], ["target_id", 554], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 01:01:27.118246"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 554 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 554 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.124421"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.124421"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 555 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.128046"], ["state", "pending"], ["target_id", 555], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.128046"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 555) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.131250"], ["group_id", 1], ["target_id", 555], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.131250"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 555 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 555 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.138220"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.138220"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 556 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.141345"], ["state", "pending"], ["target_id", 556], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.141345"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.8ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 556 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.8ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (1.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'oxy0UkGmRIrXev0tmsifvAc44m1TszhNugMvAypCOY6Q' LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.148819"], ["target_id", 556], ["target_type", "User"], ["token", "oxy0UkGmRIrXev0tmsifvAc44m1TszhNugMvAypCOY6Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.148819"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.157148"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.157148"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 557 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.160997"], ["state", "pending"], ["target_id", 557], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.160997"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 557 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'KsJtpwlS_BtW4AFX0NZ3Qwr1YjKpVSBIcJuoGMHGxYdw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.165817"], ["target_id", 557], ["target_type", "User"], ["token", "KsJtpwlS_BtW4AFX0NZ3Qwr1YjKpVSBIcJuoGMHGxYdw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.165817"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 557 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.172589"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.172589"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 558 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.175801"], ["state", "pending"], ["target_id", 558], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.175801"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 558 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'UHK3SijZA4zZv1i4nhWFEAHdVN83-BV9QBNexyN6Q35A' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.179139"], ["target_id", 558], ["target_type", "User"], ["token", "UHK3SijZA4zZv1i4nhWFEAHdVN83-BV9QBNexyN6Q35A"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.179139"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 73 [["active", "f"], ["updated_at", "2015-09-07 01:01:27.181600"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 558 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'AATh4pDHyDPS1Lj403NB5w4Jb2kBLNJfZXkC12ChGeLw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.184441"], ["target_id", 558], ["target_type", "User"], ["token", "AATh4pDHyDPS1Lj403NB5w4Jb2kBLNJfZXkC12ChGeLw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.184441"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.189656"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.189656"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 559 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 559) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:27.194083"], ["target_id", 559], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.194083"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.197483"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.197483"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 560 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 560) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:27.201879"], ["target_id", 560], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.201879"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 560 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.207314"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.207314"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 561) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:27.210870"], ["target_id", 561], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.210870"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 561 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 123]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.217129"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.217129"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 562) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:27.219726"], ["target_id", 562], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-07 01:01:27.219726"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 562 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.224584"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.224584"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 563) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.227610"], ["group_id", 1], ["target_id", 563], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.227610"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 563 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 125]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.233802"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.233802"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 564) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.236673"], ["group_id", 1], ["target_id", 564], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.236673"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 564 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.242329"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.242329"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 565) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:27.245353"], ["target_id", 565], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.245353"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 565 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.250248"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.250248"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 566) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:27.252911"], ["target_id", 566], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.252911"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 566 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.258462"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.258462"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 567) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:01:27.262180"], ["target_id", 567], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.262180"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 567) LIMIT 1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 567 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 567 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 129]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 567 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.272209"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.272209"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 568 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.276811"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.276811"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Z2BG1cIcoI7rY9zazpOmzgiXD3nNaZX-f6cfWkuqDWHg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.278678"], ["target_id", 569], ["target_type", "User"], ["token", "Z2BG1cIcoI7rY9zazpOmzgiXD3nNaZX-f6cfWkuqDWHg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.278678"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Z2BG1cIcoI7rY9zazpOmzgiXD3nNaZX-f6cfWkuqDWHg' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.283671"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.283671"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ckOVJszXoUIXdv2dp2FWtgykWOnrVMyHEu9kdppo8qkA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.285841"], ["target_id", 570], ["target_type", "User"], ["token", "ckOVJszXoUIXdv2dp2FWtgykWOnrVMyHEu9kdppo8qkA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.285841"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 76 [["active", "f"], ["updated_at", "2015-09-07 01:01:27.288974"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ckOVJszXoUIXdv2dp2FWtgykWOnrVMyHEu9kdppo8qkA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.292550"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.292550"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'yXayiunyti8qAGWOxpMN9wUSPjAkc7vunVwSvypy81Ig' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.294374"], ["target_id", 571], ["target_type", "User"], ["token", "yXayiunyti8qAGWOxpMN9wUSPjAkc7vunVwSvypy81Ig"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.294374"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 77 [["active", "f"], ["updated_at", "2015-09-07 01:01:27.298136"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:01:27.301054"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:01:27.301054"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '8sy4P7BMBKz7lYjdrBfRpw2gwPKouyADafxX64xydtEw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:01:27.302792"], ["target_id", 572], ["target_type", "User"], ["token", "8sy4P7BMBKz7lYjdrBfRpw2gwPKouyADafxX64xydtEw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:01:27.302792"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:09.483637"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:09.483637"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.3ms) Completed 200 OK in 17ms (Views: 13.8ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:09.515930"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:09.515930"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 574 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.542157"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 574], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.542157"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 574 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 574 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 12ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:09.563092"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:09.563092"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 575 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.570517"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 575], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.570517"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 575 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 575 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:09.584015"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:09.584015"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 576 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.590107"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 576], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.590107"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 576 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.593842"], ["parent_id", 1], ["state", "pending"], ["target_id", 576], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.593842"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 576 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 576 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:09.607709"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:09.607709"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 577 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.613198"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 577], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.613198"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 577 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.618279"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 577], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.618279"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 577 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.622342"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 577], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.622342"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 577 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 157ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:09.789216"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:09.789216"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 578 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.795432"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 578], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.795432"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 578 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.798915"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 578], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.798915"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 578 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.803326"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 578], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.803326"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"705"} NotifyUser::BaseNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 578 AND "notify_user_notifications"."target_type" = 'User' AND (id = '705') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 578]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 578 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 705 [["state", "read"], ["updated_at", "2015-09-07 01:02:09.819857"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 17ms (Views: 1.5ms | ActiveRecord: 2.2ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 705 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:09.839813"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:09.839813"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 579 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.847324"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 579], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.847324"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 579 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.851362"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 579], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.851362"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 579 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.855034"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 579], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.855034"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"708"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 579 AND "notify_user_notifications"."target_type" = 'User' AND (id = '708') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 579]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 579 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 708 [["state", "read"], ["updated_at", "2015-09-07 01:02:09.864956"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.4ms | ActiveRecord: 1.7ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"708"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 579 AND "notify_user_notifications"."target_type" = 'User' AND (id = '708') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.2ms | ActiveRecord: 2.2ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:09.876003"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:09.876003"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 580 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.883470"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 580], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.883470"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 580 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.887589"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 580], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.887589"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 580 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.891162"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 580], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.891162"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 580 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 580 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 4ms (Views: 1.0ms | ActiveRecord: 1.0ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 580 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:09.906208"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:09.906208"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 4ms (Views: 2.4ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:09.925312"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:09.925312"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 4ms (Views: 2.1ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:09.942346"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:09.942346"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 583 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.949528"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 583], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.949528"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["714"]} SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 583 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('714')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 583 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('714')) Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:09.966877"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:09.966877"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 584 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:09.976056"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 584], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:09.976056"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["715"]} SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 584 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('715')) NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 584 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('715')) Completed 500 Internal Server Error in 7ms  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:09.994597"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:09.994597"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 585 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.003099"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 585], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.003099"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 585 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 585 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 585) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:10.023561"], ["target_id", 585], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.023561"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 585 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 20ms (Views: 2.1ms | ActiveRecord: 1.9ms) NotifyUser::Unsubscribe Load (0.6ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 585 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.037701"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.037701"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 586 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.044507"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 586], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.044507"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 586 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 586 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 586 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 7ms (Views: 2.4ms | ActiveRecord: 0.7ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 586 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.073187"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.073187"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 587 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.080715"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 587], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.080715"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 587 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 587) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:10.089048"], ["target_id", 587], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.089048"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 587 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 7ms (ActiveRecord: 1.8ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.098055"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.098055"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 588 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.103990"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 588], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.103990"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 588) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:10.107532"], ["target_id", 588], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.107532"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 588 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 132]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 4ms (ActiveRecord: 1.0ms) NotifyUser::Unsubscribe Load (0.2ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.120487"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.120487"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 589 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.126367"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 589], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.126367"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 589 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'sTZwo3wv2pX9xUx7Dd3b3wBN3UbL00vU9KxrSnNz1oxg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.138397"], ["target_id", 589], ["target_type", "User"], ["token", "sTZwo3wv2pX9xUx7Dd3b3wBN3UbL00vU9KxrSnNz1oxg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.138397"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"sTZwo3wv2pX9xUx7Dd3b3wBN3UbL00vU9KxrSnNz1oxg"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'sTZwo3wv2pX9xUx7Dd3b3wBN3UbL00vU9KxrSnNz1oxg' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'sTZwo3wv2pX9xUx7Dd3b3wBN3UbL00vU9KxrSnNz1oxg' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 589]]  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 589) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:10.149782"], ["target_id", 589], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.149782"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 79 [["active", "f"], ["updated_at", "2015-09-07 01:02:10.151674"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.3ms | ActiveRecord: 2.4ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 221.8ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.1ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.0ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.415481"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.415481"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 590 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.419016"], ["state", "pending"], ["target_id", 590], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.419016"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.423782"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.423782"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 591 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.427793"], ["state", "pending"], ["target_id", 591], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.427793"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.433427"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.433427"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 592 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.437278"], ["state", "pending"], ["target_id", 592], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.437278"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.442102"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.442102"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 593 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.445391"], ["state", "pending"], ["target_id", 593], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.445391"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.449661"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.449661"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 594 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.452955"], ["state", "pending"], ["target_id", 594], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.452955"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 594 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.458502"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.458502"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 595 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.461565"], ["state", "pending"], ["target_id", 595], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.461565"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.465724"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.465724"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 596 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.469447"], ["state", "pending"], ["target_id", 596], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.469447"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.473326"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.473326"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 597 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.476839"], ["state", "pending"], ["target_id", 597], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.476839"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 597 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 728 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 01:02:10.480198"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.486158"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.486158"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 598 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.489888"], ["state", "pending"], ["target_id", 598], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.489888"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 598 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 729 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 01:02:10.492829"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.498144"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.498144"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.501620"], ["state", "pending"], ["target_id", 599], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.501620"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 730 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 01:02:10.504528"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.509819"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.509819"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.513268"], ["state", "pending"], ["target_id", 600], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.513268"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 731 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 01:02:10.516212"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.521803"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.521803"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.525102"], ["state", "pending"], ["target_id", 601], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.525102"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.530611"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.530611"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.534972"], ["state", "pending"], ["target_id", 602], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.534972"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 733 [["state", "sent"], ["updated_at", "2015-09-07 01:02:10.540176"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 733 [["sent_time", "2015-09-07 01:02:10.541422"], ["updated_at", "2015-09-07 01:02:10.542877"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.547495"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.547495"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 603 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.550679"], ["state", "pending"], ["target_id", 603], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.550679"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 603 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 603 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 734)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 603 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 734 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:10.556251"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 734]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 603]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 603 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 603]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 603 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 734 [["sent_time", "2015-09-07 01:02:10.562737"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:10.565582"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 603 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 734]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 603]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 603 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 603 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 603 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'lTu5hPINdklFklRA2E2rIA1Ml7Fnhm1_BP7V1fmFi_PA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.576562"], ["target_id", 603], ["target_type", "User"], ["token", "lTu5hPINdklFklRA2E2rIA1Ml7Fnhm1_BP7V1fmFi_PA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.576562"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.4ms Sent mail to user@example.com (4.8ms) Date: Mon, 07 Sep 2015 11:02:10 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ece2128defd_f6d13fd5ad460204760be@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.586975"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.586975"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 604 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.590155"], ["state", "pending_as_aggregation_parent"], ["target_id", 604], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.590155"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 604 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.593664"], ["state", "pending"], ["target_id", 604], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.593664"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 604 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 604 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 736)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.600581"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.600581"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.604655"], ["state", "pending"], ["target_id", 605], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.604655"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 737 [["state", "sent"], ["updated_at", "2015-09-07 01:02:10.608648"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 737 [["sent_time", "2015-09-07 01:02:10.609927"], ["updated_at", "2015-09-07 01:02:10.611395"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 737]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 605]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 605 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '4i5HMXNJ3YKLl9P9d9WmQAgL3W_9aoZy-pTEr2c9mdBg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.620538"], ["target_id", 605], ["target_type", "User"], ["token", "4i5HMXNJ3YKLl9P9d9WmQAgL3W_9aoZy-pTEr2c9mdBg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.620538"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.8ms Sent mail to user@example.com (1.6ms) Date: Mon, 07 Sep 2015 11:02:10 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ece21298636_f6d13fd5ad4602047615c@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.628768"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.628768"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 606 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.634109"], ["state", "pending"], ["target_id", 606], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.634109"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 606 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 738 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-07 01:02:10.637550"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.641896"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.641896"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.645270"], ["state", "pending"], ["target_id", 607], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.645270"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 607) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:10.648063"], ["target_id", 607], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 01:02:10.648063"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 739]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 607]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.656412"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.656412"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 608 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.659474"], ["state", "pending"], ["target_id", 608], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.659474"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 740]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 608]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 608 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 608 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.667692"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.667692"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 609 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.671063"], ["state", "pending"], ["target_id", 609], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.671063"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 609 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 609 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 741 [["state", "sent"], ["updated_at", "2015-09-07 01:02:10.676246"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 609 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 741 [["sent_time", "2015-09-07 01:02:10.677541"], ["updated_at", "2015-09-07 01:02:10.678938"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 741]] User Load (0.5ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 609]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 609 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 609 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 609 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '-M1hkXPsT7IQs3kgwONRuQj3aug5lyrgkPDhPcLXAK5w' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.688215"], ["target_id", 609], ["target_type", "User"], ["token", "-M1hkXPsT7IQs3kgwONRuQj3aug5lyrgkPDhPcLXAK5w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.688215"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.2ms Sent mail to user@example.com (1.6ms) Date: Mon, 07 Sep 2015 11:02:10 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ece212a8cf7_f6d13fd5ad460204762d3@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.695457"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.695457"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 610 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.699379"], ["state", "pending"], ["target_id", 610], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.699379"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 742]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 610]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 610 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 610 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.707949"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.707949"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 611 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.711202"], ["state", "pending"], ["target_id", 611], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.711202"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 743]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 611]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 611 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 611]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 611 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 743 [["sent_time", "2015-09-07 01:02:10.715848"], ["state", "sent"], ["updated_at", "2015-09-07 01:02:10.718335"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 611 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.724245"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.724245"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.727518"], ["state", "pending"], ["target_id", 612], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.727518"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.732664"], ["state", "pending"], ["target_id", 612], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.732664"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 745]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 612]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 612 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 612]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 745 [["sent_time", "2015-09-07 01:02:10.737586"], ["state", "sent"], ["updated_at", "2015-09-07 01:02:10.740138"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 612]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 744 [["sent_time", "2015-09-07 01:02:10.742090"], ["state", "sent"], ["updated_at", "2015-09-07 01:02:10.744574"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.753135"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.753135"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.756335"], ["state", "read"], ["target_id", 613], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.756335"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 746]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 613]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 613 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.763289"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.763289"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.771694"], ["group_id", 2], ["state", "pending"], ["target_id", 614], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.771694"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 747]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 614]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 614 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 614]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 747 [["sent_time", "2015-09-07 01:02:10.779058"], ["state", "sent"], ["updated_at", "2015-09-07 01:02:10.783750"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 747]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 614]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 614 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'yed_EIZNwWjEeyNT2l-EFgqsUqm5AGbeTmXgqqKaPSFw' LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:10.796544"], ["target_id", 614], ["target_type", "User"], ["token", "yed_EIZNwWjEeyNT2l-EFgqsUqm5AGbeTmXgqqKaPSFw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.796544"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.6ms Sent mail to user@example.com (1.8ms) Date: Mon, 07 Sep 2015 11:02:10 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ece212c3a2f_f6d13fd5ad46020476386@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.805360"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.805360"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 615 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 615 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.809810"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 615], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.809810"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 615 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 615 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 748 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:10.814267"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 615 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 615 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 748 [["sent_time", "2015-09-07 01:02:10.815597"], ["updated_at", "2015-09-07 01:02:10.818097"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 748]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.825128"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.825128"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 616 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 616 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.829285"], ["group_id", 1], ["state", "pending"], ["target_id", 616], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.829285"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 616 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 749) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.835155"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.835155"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 617 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 617 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.840050"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 617], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.840050"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 617 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 617 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.844275"], ["group_id", 1], ["state", "pending"], ["target_id", 617], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.844275"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 617 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 751) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.850967"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.850967"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.855333"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 618], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.855333"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.860083"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 618], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.860083"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.864335"], ["group_id", 1], ["state", "pending"], ["target_id", 618], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.864335"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 618 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 754) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.878930"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.878930"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 619 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 619 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.883811"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 619], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.883811"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 619 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 619 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.888609"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 619], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.888609"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 619 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 619 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.893200"], ["group_id", 1], ["state", "pending"], ["target_id", 619], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.893200"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 619 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 757) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.899637"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.899637"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.905120"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 620], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.905120"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.909545"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 620], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.909545"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.914227"], ["group_id", 1], ["state", "pending"], ["target_id", 620], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.914227"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 620 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 760) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.920956"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.920956"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 621 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 621 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 15:02:10.922280"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 621], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.925908"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 621 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 01:02:10.928323') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 621 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 01:02:10.928323') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 621 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 621 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 01:02:10.934385"], ["group_id", 1], ["parent_id", 761], ["state", "pending"], ["target_id", 621], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.934385"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.939153"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.939153"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 622 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 622 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 00:02:10.940449"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 622], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.943797"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 622 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 01:02:10.945816')  (0.3ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 622 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 622 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.955449"], ["group_id", 1], ["state", "pending"], ["target_id", 622], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.955449"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.963413"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.963413"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 623 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 623 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 00:02:10.965767"], ["group_id", 1], ["state", "pending"], ["target_id", 623], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.972833"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 623 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 01:02:10.976588')  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 623 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 623 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.0ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:10.985175"], ["group_id", 1], ["state", "pending"], ["target_id", 623], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:10.985175"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.4ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:10.994531"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:10.994531"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 624 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 624 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.006576"], ["group_id", 1], ["state", "pending"], ["target_id", 624], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.006576"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 624 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 767) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 624 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 767) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.019377"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.019377"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 625 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 625 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.026819"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 625], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.026819"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 625 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 625 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 768 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.034190"]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 625 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 625 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 768 [["sent_time", "2015-09-07 01:02:11.036526"], ["updated_at", "2015-09-07 01:02:11.041088"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 625 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 625 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.049102"], ["group_id", 1], ["state", "pending"], ["target_id", 625], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.049102"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 625 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 769) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 625 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 769) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.063024"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.063024"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.068194"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 626], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.068194"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 770 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.072908"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 770 [["sent_time", "2015-09-07 01:02:11.074133"], ["updated_at", "2015-09-07 01:02:11.077093"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.082456"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 626], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.082456"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 771 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.086951"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 771 [["sent_time", "2015-09-07 01:02:11.088443"], ["updated_at", "2015-09-07 01:02:11.091341"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.096824"], ["group_id", 1], ["state", "pending"], ["target_id", 626], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.096824"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 626 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 772) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 626 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 772) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.106904"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.106904"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.112035"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 627], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.112035"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 773 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.116711"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 773 [["sent_time", "2015-09-07 01:02:11.117975"], ["updated_at", "2015-09-07 01:02:11.120409"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.125272"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 627], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.125272"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 774 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.129357"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 774 [["sent_time", "2015-09-07 01:02:11.130554"], ["updated_at", "2015-09-07 01:02:11.133091"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.137657"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 627], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.137657"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 775 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.142638"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 775 [["sent_time", "2015-09-07 01:02:11.143804"], ["updated_at", "2015-09-07 01:02:11.146418"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.151945"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 627], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.151945"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 776 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.156802"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 776 [["sent_time", "2015-09-07 01:02:11.158097"], ["updated_at", "2015-09-07 01:02:11.160906"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.165699"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 627], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.165699"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 777 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.169891"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 777 [["sent_time", "2015-09-07 01:02:11.171151"], ["updated_at", "2015-09-07 01:02:11.173853"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.178854"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 627], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.178854"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 778 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.183041"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 778 [["sent_time", "2015-09-07 01:02:11.184193"], ["updated_at", "2015-09-07 01:02:11.186661"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.191165"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 627], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.191165"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 779 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.195573"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 779 [["sent_time", "2015-09-07 01:02:11.196793"], ["updated_at", "2015-09-07 01:02:11.199508"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.203924"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 627], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.203924"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 780 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.208356"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 780 [["sent_time", "2015-09-07 01:02:11.209737"], ["updated_at", "2015-09-07 01:02:11.212507"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.217082"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 627], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.217082"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 781 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.221510"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 781 [["sent_time", "2015-09-07 01:02:11.222755"], ["updated_at", "2015-09-07 01:02:11.225251"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.230186"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 627], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.230186"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 782 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.234422"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 782 [["sent_time", "2015-09-07 01:02:11.235660"], ["updated_at", "2015-09-07 01:02:11.238087"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.243115"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 627], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.243115"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 783 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.247501"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 783 [["sent_time", "2015-09-07 01:02:11.248802"], ["updated_at", "2015-09-07 01:02:11.251465"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.256011"], ["group_id", 1], ["state", "pending"], ["target_id", 627], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.256011"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 627 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 784) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 627 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 784) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.264510"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.264510"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 628 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 628 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.269605"], ["group_id", 1], ["state", "pending"], ["target_id", 628], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.269605"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 628 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 628 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 628 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 785)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 628 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 628 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 785 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.280829"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.285754"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.285754"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 629 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 629 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.290380"], ["group_id", 1], ["state", "pending"], ["target_id", 629], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.290380"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 629 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 629 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 629 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 786)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 629 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 629 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 786 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.299754"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.305480"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.305480"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 630 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 630 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.310380"], ["group_id", 1], ["state", "pending"], ["target_id", 630], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.310380"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 630 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 630 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 630 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 787)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 630 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 630 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 787 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.319782"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 787]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.325997"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.325997"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 631 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 631 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.330688"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 631], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.330688"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 631 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 631 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:04:11.330688"], ["group_id", 1], ["state", "pending"], ["target_id", 631], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.340663"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 631 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 631 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 631 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 789)  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 631 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 631 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 789 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 01:02:11.351103"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.356689"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.356689"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 632 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 632 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.361068"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 632], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.361068"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 632 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 01:02:11.363705') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 632 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 01:02:11.363705') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 632 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 632 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 01:04:11.361068"], ["group_id", 1], ["parent_id", 790], ["state", "pending"], ["target_id", 632], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.369311"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 791]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.374832"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.374832"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 633 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 633 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.378943"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 633], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.378943"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 633 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 633 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.383541"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 633], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.383541"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 633 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 633 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.388112"], ["group_id", 1], ["state", "pending"], ["target_id", 633], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.388112"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 633 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 633 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 633 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 794)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.396601"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.396601"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 634 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 634 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.401762"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 634], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.401762"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 634 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 634 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.406463"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 634], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.406463"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 634 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 634 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:02:11.410625"], ["group_id", 1], ["state", "pending"], ["target_id", 634], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.410625"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 634 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 634 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 634 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 797) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 797]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.420321"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.420321"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 635 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.426013"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.426013"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 636 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 636 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.432435"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.432435"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 637 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.437917"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.437917"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 638 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.441486"], ["state", "pending"], ["target_id", 638], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.441486"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 638) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:11.444388"], ["target_id", 638], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.444388"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 638 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.7ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.450457"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.450457"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 639 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.454228"], ["state", "pending"], ["target_id", 639], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.454228"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 639 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.459236"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.459236"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 640 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.462465"], ["state", "pending"], ["target_id", 640], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.462465"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 640) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:11.465423"], ["target_id", 640], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 01:02:11.465423"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 640 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 640 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.471129"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.471129"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 641 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.474806"], ["state", "pending"], ["target_id", 641], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.474806"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 641 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 641 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.480659"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.480659"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 642 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.483963"], ["state", "pending"], ["target_id", 642], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.483963"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 642) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.487420"], ["group_id", 1], ["target_id", 642], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.487420"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 642 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 642 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.494514"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.494514"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 643 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.498020"], ["state", "pending"], ["target_id", 643], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.498020"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 643) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:11.502034"], ["target_id", 643], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.502034"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 643 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 643 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.509262"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.509262"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 644 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.512254"], ["state", "pending"], ["target_id", 644], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.512254"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 644 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 644 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 804 [["group_id", 1], ["updated_at", "2015-09-07 01:02:11.516427"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 644 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 644 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.523317"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.523317"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 645 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.526502"], ["state", "pending"], ["target_id", 645], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.526502"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 805]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 645]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 645 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 645 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.534418"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.534418"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 646 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.537978"], ["state", "pending"], ["target_id", 646], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.537978"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 646) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:11.541146"], ["target_id", 646], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 01:02:11.541146"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 806]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 646]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 646 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 646 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.549330"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.549330"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 647 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.552760"], ["state", "pending"], ["target_id", 647], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.552760"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 647) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.555688"], ["group_id", 1], ["target_id", 647], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.555688"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 647 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 807]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 647]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 647 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.564439"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.564439"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 648 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.567906"], ["state", "pending"], ["target_id", 648], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.567906"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 648 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 648 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.575194"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.575194"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 649 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.578545"], ["state", "pending"], ["target_id", 649], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.578545"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 649) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:11.581312"], ["target_id", 649], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 01:02:11.581312"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 649 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 649 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.587682"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.587682"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 650 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.590861"], ["state", "pending"], ["target_id", 650], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.590861"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 650) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.593684"], ["group_id", 1], ["target_id", 650], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.593684"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 650 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 650 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.601959"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.601959"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 651 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.605460"], ["state", "pending"], ["target_id", 651], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.605460"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 651 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'bC_yWR90yh-Ag8rDdDmiIg5Zo5RBBnmRNISRNG2otfXg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.608768"], ["target_id", 651], ["target_type", "User"], ["token", "bC_yWR90yh-Ag8rDdDmiIg5Zo5RBBnmRNISRNG2otfXg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.608768"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.613629"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.613629"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 652 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.617260"], ["state", "pending"], ["target_id", 652], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.617260"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 652 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'X_wiEVeXq_OuOSJ67Gsp6AMUsSHM6cblQGXvkodurP6g' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.620859"], ["target_id", 652], ["target_type", "User"], ["token", "X_wiEVeXq_OuOSJ67Gsp6AMUsSHM6cblQGXvkodurP6g"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.620859"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 652 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.627046"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.627046"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 653 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.631094"], ["state", "pending"], ["target_id", 653], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.631094"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 653 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'yrt7jo2F3vjoBMKIjgo_Jgl6QMrJFrlpDWKCOXgxBz2w' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.634497"], ["target_id", 653], ["target_type", "User"], ["token", "yrt7jo2F3vjoBMKIjgo_Jgl6QMrJFrlpDWKCOXgxBz2w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.634497"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 86 [["active", "f"], ["updated_at", "2015-09-07 01:02:11.637671"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 653 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'uLO6sf4CHjqnM3X3Z7sA-QXdRuBQjp8-0ITlzrohlZ2Q' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.640946"], ["target_id", 653], ["target_type", "User"], ["token", "uLO6sf4CHjqnM3X3Z7sA-QXdRuBQjp8-0ITlzrohlZ2Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.640946"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.646060"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.646060"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 654 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 654) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:11.651084"], ["target_id", 654], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.651084"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.655178"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.655178"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 655 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 655) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:11.658877"], ["target_id", 655], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.658877"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 655 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.664015"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.664015"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 656) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:11.666645"], ["target_id", 656], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.666645"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 656 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 145]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.673574"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.673574"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 657) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:11.676439"], ["target_id", 657], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-07 01:02:11.676439"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 657 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.681197"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.681197"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 658) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.683867"], ["group_id", 1], ["target_id", 658], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.683867"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 658 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 147]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.690435"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.690435"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 659) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.693404"], ["group_id", 1], ["target_id", 659], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.693404"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 659 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.699715"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.699715"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 660) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:11.702705"], ["target_id", 660], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.702705"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 660 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.707544"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.707544"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 661) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:11.710629"], ["target_id", 661], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.710629"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 661 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.716221"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.716221"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 662) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 01:02:11.719530"], ["target_id", 662], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.719530"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 662) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 662 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 662 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 151]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 662 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.729970"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.729970"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.735211"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.735211"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '-4OkIvsbhO2o98lJw_u_OwwQoffpM-EdFu-K7QEI0SAw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.737008"], ["target_id", 664], ["target_type", "User"], ["token", "-4OkIvsbhO2o98lJw_u_OwwQoffpM-EdFu-K7QEI0SAw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.737008"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '-4OkIvsbhO2o98lJw_u_OwwQoffpM-EdFu-K7QEI0SAw' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.742511"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.742511"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '-7t4mJTFkiAYyA9EBw3dCwExs1X_4mpahaw1PeI0_0KA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.744309"], ["target_id", 665], ["target_type", "User"], ["token", "-7t4mJTFkiAYyA9EBw3dCwExs1X_4mpahaw1PeI0_0KA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.744309"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 89 [["active", "f"], ["updated_at", "2015-09-07 01:02:11.747218"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '-7t4mJTFkiAYyA9EBw3dCwExs1X_4mpahaw1PeI0_0KA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (1.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.752532"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.752532"]]  (0.7ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'R_mdhr1JPJB5WnmZFqQmRwBQp6xFcU25nUo_pqm_lVrA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.760892"], ["target_id", 666], ["target_type", "User"], ["token", "R_mdhr1JPJB5WnmZFqQmRwBQp6xFcU25nUo_pqm_lVrA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.760892"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 90 [["active", "f"], ["updated_at", "2015-09-07 01:02:11.764295"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:02:11.767287"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:02:11.767287"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '3m4gZXEo7PEiEn8Nvg9J3Ao7A-EgeEqAZmybpPUVBnaQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:02:11.769909"], ["target_id", 667], ["target_type", "User"], ["token", "3m4gZXEo7PEiEn8Nvg9J3Ao7A-EgeEqAZmybpPUVBnaQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:02:11.769909"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.4ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 User Load (0.6ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1]]  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1]]  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1]]  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1]]  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1]]  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1]]  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:08:32.743116"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-07 01:08:32.743116"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 668 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = ''  (0.9ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:08:40.560910"], ["email", "2@notifyuser.com"], ["updated_at", "2015-09-07 01:08:40.560910"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 669 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = ''  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:08:59.734364"], ["email", "3@notifyuser.com"], ["updated_at", "2015-09-07 01:08:59.734364"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 670 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = ''  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:09:07.050144"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-07 01:09:07.050144"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 671 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = ''  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (2.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:10:09.760172"], ["email", "2@notifyuser.com"], ["updated_at", "2015-09-07 01:10:09.760172"]]  (1.8ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 672 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = ''  (0.4ms) ROLLBACK TO SAVEPOINT active_record_1  (0.5ms) ROLLBACK  (3.4ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:10:16.907883"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-07 01:10:16.907883"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 673 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:10:16.926440"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 673], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:10:16.926440"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:10:24.115112"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-07 01:10:24.115112"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 674 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:10:24.144116"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 674], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:10:24.144116"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:13:15.998216"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-07 01:13:15.998216"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 675 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:13:16.028201"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 675], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:13:16.028201"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:15:15.983589"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-07 01:15:15.983589"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 676 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:15:16.005217"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 676], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:15:16.005217"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:17:13.859044"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-07 01:17:13.859044"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 677 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 01:17:13.879439"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 677], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:17:13.879439"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:28:16.470315"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:28:16.470315"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 678 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:28:16.504482"], ["state", "pending"], ["target_id", 678], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:28:16.504482"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:28:16.510265"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:28:16.510265"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 679 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:28:16.514138"], ["state", "pending"], ["target_id", 679], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:28:16.514138"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:28:16.518766"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:28:16.518766"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 680 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:28:16.521995"], ["state", "pending"], ["target_id", 680], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:28:16.521995"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:28:16.526660"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:28:16.526660"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 681 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:28:16.530132"], ["state", "pending"], ["target_id", 681], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:28:16.530132"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:29:13.297612"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:29:13.297612"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 682 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:29:13.327066"], ["state", "pending"], ["target_id", 682], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:29:13.327066"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:29:13.331930"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:29:13.331930"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 683 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:29:13.336054"], ["state", "pending"], ["target_id", 683], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:29:13.336054"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:29:13.340421"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:29:13.340421"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 684 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:29:13.343807"], ["state", "pending"], ["target_id", 684], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:29:13.343807"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:29:13.347862"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:29:13.347862"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 685 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:29:13.351030"], ["state", "pending"], ["target_id", 685], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:29:13.351030"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:29:28.708211"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:29:28.708211"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 686 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:29:28.740968"], ["state", "pending"], ["target_id", 686], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:29:28.740968"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:29:28.745993"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:29:28.745993"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 687 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:29:28.750086"], ["state", "pending"], ["target_id", 687], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:29:28.750086"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:29:28.754282"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:29:28.754282"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 688 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:29:28.757790"], ["state", "pending"], ["target_id", 688], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:29:28.757790"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:29:28.761551"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:29:28.761551"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 689 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:29:28.765687"], ["state", "pending"], ["target_id", 689], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:29:28.765687"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:30:13.280389"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:30:13.280389"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 690 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:30:13.308716"], ["state", "pending"], ["target_id", 690], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:30:13.308716"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:30:13.313757"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:30:13.313757"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 691 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:30:13.317656"], ["state", "pending"], ["target_id", 691], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:30:13.317656"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:30:13.321772"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:30:13.321772"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 692 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:30:13.325458"], ["state", "pending"], ["target_id", 692], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:30:13.325458"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:30:13.329686"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:30:13.329686"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 693 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:30:13.333098"], ["state", "pending"], ["target_id", 693], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:30:13.333098"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:32:27.455186"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:32:27.455186"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 694 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:32:27.485032"], ["state", "pending"], ["target_id", 694], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:32:27.485032"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:32:27.490524"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:32:27.490524"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 695 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:32:27.494538"], ["state", "pending"], ["target_id", 695], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:32:27.494538"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:32:27.498942"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:32:27.498942"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 696 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:32:27.502134"], ["state", "pending"], ["target_id", 696], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:32:27.502134"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:32:27.506305"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:32:27.506305"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 697 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:32:27.509583"], ["state", "pending"], ["target_id", 697], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:32:27.509583"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:33:18.202067"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:33:18.202067"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 698 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:33:18.231860"], ["state", "pending"], ["target_id", 698], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:33:18.231860"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 698 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:33:18.255567"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:33:18.255567"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 699 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:33:18.259923"], ["state", "pending"], ["target_id", 699], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:33:18.259923"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 699 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:33:18.265980"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:33:18.265980"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 700 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:33:18.269518"], ["state", "pending"], ["target_id", 700], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:33:18.269518"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 700 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:33:18.276468"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:33:18.276468"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 701 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:33:18.280388"], ["state", "pending"], ["target_id", 701], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:33:18.280388"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 701 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:34:17.188283"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:34:17.188283"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 702 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:34:17.226631"], ["state", "pending"], ["target_id", 702], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:34:17.226631"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 702 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:34:17.246188"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:34:17.246188"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:34:17.250183"], ["state", "pending"], ["target_id", 703], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:34:17.250183"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 703 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:34:17.256978"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:34:17.256978"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 704 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:34:17.260661"], ["state", "pending"], ["target_id", 704], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:34:17.260661"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 704 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:34:33.926061"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:34:33.926061"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 705 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:34:33.956446"], ["state", "pending"], ["target_id", 705], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:34:33.956446"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 705 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:41:22.829204"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:41:22.829204"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 706 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:41:22.858854"], ["state", "pending"], ["target_id", 706], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:41:22.858854"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 706 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:41:22.875308"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:41:22.875308"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 707 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:41:22.878669"], ["state", "pending"], ["target_id", 707], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:41:22.878669"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 707 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:42:26.170610"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:42:26.170610"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 708 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:42:26.199062"], ["state", "pending"], ["target_id", 708], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:42:26.199062"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 708 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:42:26.218991"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:42:26.218991"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 709 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:42:26.222966"], ["state", "pending"], ["target_id", 709], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:42:26.222966"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 709 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:44:50.592887"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:44:50.592887"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 710 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:44:50.620327"], ["state", "pending"], ["target_id", 710], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:44:50.620327"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 710 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:44:50.629554"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:44:50.629554"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 711 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:44:50.633267"], ["state", "pending"], ["target_id", 711], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:44:50.633267"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 711 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:49:24.586758"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:49:24.586758"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 712 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:49:24.615698"], ["state", "pending"], ["target_id", 712], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:49:24.615698"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 712 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:49:24.623912"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:49:24.623912"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 713 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:49:24.627381"], ["state", "pending"], ["target_id", 713], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:49:24.627381"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 713 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:53:18.764124"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:53:18.764124"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:53:18.800556"], ["state", "pending"], ["target_id", 714], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:53:18.800556"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 714 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:53:18.810480"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:53:18.810480"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:53:18.814051"], ["state", "pending"], ["target_id", 715], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:53:18.814051"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 715 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 01:58:17.679104"], ["email", "user@example.com"], ["updated_at", "2015-09-07 01:58:17.679104"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 01:58:17.709295"], ["state", "pending"], ["target_id", 716], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 01:58:17.709295"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 716 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.6ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.183920"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.183920"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.3ms) Completed 200 OK in 27ms (Views: 19.8ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.229587"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.229587"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 718 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.256468"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 718], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.256468"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 718 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 718 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 14ms  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.279463"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.279463"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 719 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.285535"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 719], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.285535"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 719 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 719 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.298469"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.298469"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.304049"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 720], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.304049"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.307443"], ["parent_id", 1], ["state", "pending"], ["target_id", 720], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.307443"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 720 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 720 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.321204"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.321204"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 721 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.327725"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 721], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.327725"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 721 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.331145"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 721], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.331145"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 721 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.334552"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 721], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.334552"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 721 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 148ms  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.494007"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.494007"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.501957"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 722], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.501957"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.506286"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 722], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.506286"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.510176"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 722], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.510176"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"865"} NotifyUser::BaseNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 722 AND "notify_user_notifications"."target_type" = 'User' AND (id = '865') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 722]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 865 [["state", "read"], ["updated_at", "2015-09-07 02:11:27.531300"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 22ms (Views: 1.9ms | ActiveRecord: 2.1ms) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 865 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.551612"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.551612"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.557954"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 723], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.557954"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.562100"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 723], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.562100"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.565941"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 723], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.565941"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"868"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 723 AND "notify_user_notifications"."target_type" = 'User' AND (id = '868') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 723]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 868 [["state", "read"], ["updated_at", "2015-09-07 02:11:27.576175"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.3ms | ActiveRecord: 1.8ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"868"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 723 AND "notify_user_notifications"."target_type" = 'User' AND (id = '868') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.2ms | ActiveRecord: 2.2ms)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.588613"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.588613"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 724 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.594848"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 724], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.594848"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 724 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.598638"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 724], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.598638"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 724 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.602308"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 724], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.602308"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 724 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 724 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 4ms (Views: 1.0ms | ActiveRecord: 1.0ms) NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 724 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.616632"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.616632"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 4ms (Views: 2.5ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.635446"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.635446"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 3ms (Views: 2.2ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.650934"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.650934"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.657645"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 727], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.657645"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["874"]} SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 727 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('874')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 727 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('874')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.6ms) SAVEPOINT active_record_1 SQL (0.9ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.676881"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.676881"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 728 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.692111"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 728], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.692111"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["875"]} SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 728 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('875')) NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 728 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('875')) Completed 500 Internal Server Error in 7ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.709778"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.709778"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 729 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.717899"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 729], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.717899"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 729 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 729 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 729) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:27.743812"], ["target_id", 729], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.743812"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 729 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 24ms (Views: 2.0ms | ActiveRecord: 1.8ms) NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 729 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.756872"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.756872"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 730 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.763811"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 730], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.763811"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 730 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 730 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 730 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 6ms (Views: 2.4ms | ActiveRecord: 0.7ms) NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 730 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.794981"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.794981"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 731 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.801547"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 731], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.801547"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 731 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 731) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:27.809303"], ["target_id", 731], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.809303"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 731 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 7ms (ActiveRecord: 1.7ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.819695"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.819695"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 732 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.826602"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 732], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.826602"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 732) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:27.830221"], ["target_id", 732], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.830221"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 732 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 154]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 4ms (ActiveRecord: 0.9ms) NotifyUser::Unsubscribe Load (0.2ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:27.844328"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:27.844328"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 733 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:27.850653"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 733], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.850653"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 733 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'J1YuQUnZ1z0yhAY0t5GQSA2GzS6IP2Zl8gDFqaFb7xSw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:27.862543"], ["target_id", 733], ["target_type", "User"], ["token", "J1YuQUnZ1z0yhAY0t5GQSA2GzS6IP2Zl8gDFqaFb7xSw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.862543"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"J1YuQUnZ1z0yhAY0t5GQSA2GzS6IP2Zl8gDFqaFb7xSw"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'J1YuQUnZ1z0yhAY0t5GQSA2GzS6IP2Zl8gDFqaFb7xSw' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'J1YuQUnZ1z0yhAY0t5GQSA2GzS6IP2Zl8gDFqaFb7xSw' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 733]]  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 733) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:27.873192"], ["target_id", 733], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:27.873192"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 92 [["active", "f"], ["updated_at", "2015-09-07 02:11:27.875066"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.3ms | ActiveRecord: 2.4ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 23.9ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.2ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.0ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.164158"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.164158"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 734 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.168082"], ["state", "pending"], ["target_id", 734], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.168082"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.173082"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.173082"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 735 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.176785"], ["state", "pending"], ["target_id", 735], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.176785"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.181992"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.181992"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 736 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.185117"], ["state", "pending"], ["target_id", 736], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.185117"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.189688"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.189688"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 737 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.193066"], ["state", "pending"], ["target_id", 737], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.193066"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.197656"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.197656"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 738 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.201179"], ["state", "pending"], ["target_id", 738], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.201179"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 738 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.207609"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.207609"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 739 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.210817"], ["state", "pending"], ["target_id", 739], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.210817"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 739 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.216601"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.216601"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 740 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.219915"], ["state", "pending"], ["target_id", 740], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.219915"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.224719"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.224719"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 741 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.228585"], ["state", "pending"], ["target_id", 741], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.228585"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.232728"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.232728"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 742 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.236222"], ["state", "pending"], ["target_id", 742], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.236222"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 742 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 889 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 02:11:28.239430"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.245560"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.245560"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 743 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.249398"], ["state", "pending"], ["target_id", 743], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.249398"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 743 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 890 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 02:11:28.252503"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.257850"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.257850"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 744 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.261857"], ["state", "pending"], ["target_id", 744], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.261857"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 744 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 891 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 02:11:28.265138"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.270373"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.270373"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 745 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.273955"], ["state", "pending"], ["target_id", 745], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.273955"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 745 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 892 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 02:11:28.276920"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.282734"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.282734"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 746 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.286221"], ["state", "pending"], ["target_id", 746], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.286221"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 746 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.291853"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.291853"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 747 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.295267"], ["state", "pending"], ["target_id", 747], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.295267"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 747 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 747 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 894 [["state", "sent"], ["updated_at", "2015-09-07 02:11:28.300119"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 747 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 894 [["sent_time", "2015-09-07 02:11:28.301477"], ["updated_at", "2015-09-07 02:11:28.303187"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.307840"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.307840"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 748 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.311690"], ["state", "pending"], ["target_id", 748], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.311690"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 748 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 748 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 895)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 748 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 895 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:28.318364"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 895]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 748]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 748 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 748]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 748 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 895 [["sent_time", "2015-09-07 02:11:28.325029"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:28.327844"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 748 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 895]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 748]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 748 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 748 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 748 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ZB06ocE7MpQwAit1lZyWKQKP_wY2iS8uUfunucFpx_8w' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.338603"], ["target_id", 748], ["target_type", "User"], ["token", "ZB06ocE7MpQwAit1lZyWKQKP_wY2iS8uUfunucFpx_8w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.338603"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.0ms Sent mail to user@example.com (6.3ms) Date: Mon, 07 Sep 2015 12:11:28 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecf250545f3_151013fffa146020459562@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.351075"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.351075"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 749 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.354634"], ["state", "pending_as_aggregation_parent"], ["target_id", 749], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.354634"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 749 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.359036"], ["state", "pending"], ["target_id", 749], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.359036"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 749 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 749 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 897)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.366323"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.366323"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 750 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.369860"], ["state", "pending"], ["target_id", 750], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.369860"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 750 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 750 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 898 [["state", "sent"], ["updated_at", "2015-09-07 02:11:28.374092"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 750 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 898 [["sent_time", "2015-09-07 02:11:28.375508"], ["updated_at", "2015-09-07 02:11:28.377053"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 898]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 750]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 750 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 750 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 750 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'rdWchatlbfRGtHjAuxGvWQ1ecrAA1hRAKLiHoClgEltg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.385975"], ["target_id", 750], ["target_type", "User"], ["token", "rdWchatlbfRGtHjAuxGvWQ1ecrAA1hRAKLiHoClgEltg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.385975"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.4ms Sent mail to user@example.com (1.6ms) Date: Mon, 07 Sep 2015 12:11:28 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecf2505f13a_151013fffa146020459691@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.393539"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.393539"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 751 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.396726"], ["state", "pending"], ["target_id", 751], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.396726"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 751 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 899 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-07 02:11:28.400270"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.404589"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.404589"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 752 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.0ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.411568"], ["state", "pending"], ["target_id", 752], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.411568"]]  (0.9ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (1.0ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 752) LIMIT 1 SQL (0.6ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:28.421983"], ["target_id", 752], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 02:11:28.421983"]]  (0.5ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 900]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 752]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 752 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 752 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.432553"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.432553"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 753 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.435838"], ["state", "pending"], ["target_id", 753], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.435838"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 901]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 753]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 753 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 753 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.443923"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.443923"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 754 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.447295"], ["state", "pending"], ["target_id", 754], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.447295"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 754 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 754 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 902 [["state", "sent"], ["updated_at", "2015-09-07 02:11:28.451685"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 754 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 902 [["sent_time", "2015-09-07 02:11:28.453067"], ["updated_at", "2015-09-07 02:11:28.455032"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 902]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 754]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 754 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 754 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 754 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Tfa18jtmH296i1Jq6zVcgQVQk4Z5HXl9euwYqo9_ITrg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.465305"], ["target_id", 754], ["target_type", "User"], ["token", "Tfa18jtmH296i1Jq6zVcgQVQk4Z5HXl9euwYqo9_ITrg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.465305"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.6ms Sent mail to user@example.com (1.8ms) Date: Mon, 07 Sep 2015 12:11:28 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecf25072793_151013fffa146020459762@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.472811"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.472811"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 755 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.476102"], ["state", "pending"], ["target_id", 755], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.476102"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 903]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 755]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 755 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 755 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.484699"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.484699"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 756 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.488064"], ["state", "pending"], ["target_id", 756], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.488064"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 904]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 756]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 756 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 756]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 756 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 904 [["sent_time", "2015-09-07 02:11:28.492885"], ["state", "sent"], ["updated_at", "2015-09-07 02:11:28.495666"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 756 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.502170"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.502170"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 757 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.505943"], ["state", "pending"], ["target_id", 757], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.505943"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 757 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.510205"], ["state", "pending"], ["target_id", 757], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.510205"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 906]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 757]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 757 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 757]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 757 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 906 [["sent_time", "2015-09-07 02:11:28.515741"], ["state", "sent"], ["updated_at", "2015-09-07 02:11:28.518304"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 757]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 757 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 905 [["sent_time", "2015-09-07 02:11:28.520146"], ["state", "sent"], ["updated_at", "2015-09-07 02:11:28.522755"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 757 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 757 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.531583"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.531583"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 758 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.535063"], ["state", "read"], ["target_id", 758], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.535063"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 907]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 758]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 758 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.542496"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.542496"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 759 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 759 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.547228"], ["group_id", 2], ["state", "pending"], ["target_id", 759], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.547228"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 908]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 759]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 759 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 759]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 759 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 759 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 908 [["sent_time", "2015-09-07 02:11:28.552783"], ["state", "sent"], ["updated_at", "2015-09-07 02:11:28.556335"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 759 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 759 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 908]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 759]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 759 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 759 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 759 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 759 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'GgqCXX-_Q-DlY0tPJvlK3AEA4onPbpuTWncqfrfpK8rA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:28.569181"], ["target_id", 759], ["target_type", "User"], ["token", "GgqCXX-_Q-DlY0tPJvlK3AEA4onPbpuTWncqfrfpK8rA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.569181"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.1ms Sent mail to user@example.com (2.2ms) Date: Mon, 07 Sep 2015 12:11:28 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ecf2508c159_151013fffa14602045989b@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.577727"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.577727"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 760 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 760 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.582016"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 760], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.582016"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 760 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 760 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 909 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:28.586308"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 760 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 760 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 909 [["sent_time", "2015-09-07 02:11:28.587646"], ["updated_at", "2015-09-07 02:11:28.590076"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 909]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.597648"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.597648"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 761 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 761 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.601931"], ["group_id", 1], ["state", "pending"], ["target_id", 761], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.601931"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 761 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 910) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.608341"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.608341"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 762 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 762 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.613158"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 762], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.613158"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 762 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 762 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.618024"], ["group_id", 1], ["state", "pending"], ["target_id", 762], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.618024"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 762 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 912) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.624347"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.624347"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 763 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 763 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.628649"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 763], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.628649"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 763 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 763 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.633521"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 763], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.633521"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 763 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 763 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.637722"], ["group_id", 1], ["state", "pending"], ["target_id", 763], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.637722"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 763 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 915) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.643528"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.643528"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 764 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 764 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.647991"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 764], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.647991"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 764 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 764 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.652163"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 764], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.652163"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 764 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 764 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.656570"], ["group_id", 1], ["state", "pending"], ["target_id", 764], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.656570"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 764 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 918) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.672679"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.672679"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 765 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 765 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.677671"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 765], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.677671"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 765 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 765 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.682618"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 765], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.682618"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 765 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 765 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.687513"], ["group_id", 1], ["state", "pending"], ["target_id", 765], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.687513"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 765 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 921) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.694005"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.694005"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 766 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 766 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 16:11:28.695175"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 766], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.698507"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 766 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 02:11:28.700668') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 766 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 02:11:28.700668') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 766 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 766 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 02:11:28.706625"], ["group_id", 1], ["parent_id", 922], ["state", "pending"], ["target_id", 766], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.706625"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.712633"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.712633"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 767 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 767 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 01:11:28.713739"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 767], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.717562"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 767 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 02:11:28.720020')  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 767 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 767 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.725386"], ["group_id", 1], ["state", "pending"], ["target_id", 767], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.725386"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.730344"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.730344"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 768 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 768 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 01:11:28.731926"], ["group_id", 1], ["state", "pending"], ["target_id", 768], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.736061"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 768 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 02:11:28.738529')  (0.6ms) SAVEPOINT active_record_1  (1.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 768 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 768 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.751918"], ["group_id", 1], ["state", "pending"], ["target_id", 768], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.751918"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.759426"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.759426"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 769 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 769 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.764944"], ["group_id", 1], ["state", "pending"], ["target_id", 769], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.764944"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 769 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 928) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 769 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 928) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.772863"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.772863"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 770 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 770 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.777214"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 770], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.777214"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 770 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 770 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 929 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:28.781484"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 770 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 770 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 929 [["sent_time", "2015-09-07 02:11:28.782696"], ["updated_at", "2015-09-07 02:11:28.786187"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 770 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 770 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.794646"], ["group_id", 1], ["state", "pending"], ["target_id", 770], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.794646"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 770 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 930) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 770 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 930) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.807622"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.807622"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.813192"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 771], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.813192"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 931 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:28.818803"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 931 [["sent_time", "2015-09-07 02:11:28.820023"], ["updated_at", "2015-09-07 02:11:28.823557"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.836672"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 771], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.836672"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 932 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:28.842842"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 932 [["sent_time", "2015-09-07 02:11:28.844550"], ["updated_at", "2015-09-07 02:11:28.847538"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.852437"], ["group_id", 1], ["state", "pending"], ["target_id", 771], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.852437"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 771 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 933) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 771 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 933) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:28.861368"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:28.861368"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.866400"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 772], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.866400"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 934 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:28.871318"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 934 [["sent_time", "2015-09-07 02:11:28.872696"], ["updated_at", "2015-09-07 02:11:28.875517"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.880343"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 772], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.880343"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 935 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:28.884801"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 935 [["sent_time", "2015-09-07 02:11:28.886051"], ["updated_at", "2015-09-07 02:11:28.888920"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.893911"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 772], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.893911"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 936 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:28.899164"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 936 [["sent_time", "2015-09-07 02:11:28.900653"], ["updated_at", "2015-09-07 02:11:28.903392"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.908936"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 772], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.908936"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 937 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:28.913527"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 937 [["sent_time", "2015-09-07 02:11:28.914790"], ["updated_at", "2015-09-07 02:11:28.917245"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.921845"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 772], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.921845"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 938 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:28.926050"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 938 [["sent_time", "2015-09-07 02:11:28.927199"], ["updated_at", "2015-09-07 02:11:28.929695"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.934153"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 772], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.934153"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 939 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:28.938029"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 939 [["sent_time", "2015-09-07 02:11:28.939306"], ["updated_at", "2015-09-07 02:11:28.941780"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.946846"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 772], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.946846"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 940 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:28.951863"]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 940 [["sent_time", "2015-09-07 02:11:28.953163"], ["updated_at", "2015-09-07 02:11:28.956206"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.0ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.963083"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 772], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.963083"]]  (0.9ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 941 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:28.978278"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 941 [["sent_time", "2015-09-07 02:11:28.979784"], ["updated_at", "2015-09-07 02:11:28.982774"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:28.988427"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 772], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:28.988427"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.0ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 942 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:28.993303"]]  (1.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.7ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 942 [["sent_time", "2015-09-07 02:11:28.997594"], ["updated_at", "2015-09-07 02:11:29.006945"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:29.014299"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 772], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.014299"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 943 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:29.018876"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 943 [["sent_time", "2015-09-07 02:11:29.020257"], ["updated_at", "2015-09-07 02:11:29.022884"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:29.027607"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 772], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.027607"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 944 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:29.032393"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 944 [["sent_time", "2015-09-07 02:11:29.033593"], ["updated_at", "2015-09-07 02:11:29.036219"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:29.040994"], ["group_id", 1], ["state", "pending"], ["target_id", 772], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.040994"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 772 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 945) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 772 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 945) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.049456"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.049456"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 773 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 773 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:29.054040"], ["group_id", 1], ["state", "pending"], ["target_id", 773], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.054040"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 773 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 773 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 773 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 946)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 773 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 773 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 946 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:29.065839"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.070786"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.070786"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 774 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 774 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:29.075674"], ["group_id", 1], ["state", "pending"], ["target_id", 774], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.075674"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 774 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 774 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 774 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 947)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 774 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 774 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 947 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:29.085901"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.091225"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.091225"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 775 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 775 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:29.096966"], ["group_id", 1], ["state", "pending"], ["target_id", 775], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.096966"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 775 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 775 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 775 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 948)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 775 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 775 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.0ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 948 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:29.105394"]]  (0.7ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 948]]  (1.0ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.124088"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.124088"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 776 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 776 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:29.128814"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 776], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.128814"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 776 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 776 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:13:29.128814"], ["group_id", 1], ["state", "pending"], ["target_id", 776], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.133600"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 776 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 776 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 776 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 950)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 776 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 776 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 950 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 02:11:29.143021"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.148108"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.148108"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 777 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 777 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:29.152648"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 777], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.152648"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 777 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 02:11:29.155177') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 777 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 02:11:29.155177') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 777 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 777 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 02:13:29.152648"], ["group_id", 1], ["parent_id", 951], ["state", "pending"], ["target_id", 777], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.160521"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 952]]  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.166386"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.166386"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 778 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 778 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:29.171213"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 778], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.171213"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 778 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 778 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:29.175886"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 778], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.175886"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 778 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 778 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:29.180116"], ["group_id", 1], ["state", "pending"], ["target_id", 778], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.180116"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 778 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 778 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 778 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 955)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.189256"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.189256"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 779 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 779 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:29.194130"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 779], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.194130"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 779 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 779 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:29.198232"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 779], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.198232"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 779 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 779 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:29.202727"], ["group_id", 1], ["state", "pending"], ["target_id", 779], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.202727"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 779 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 779 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 779 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 958) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 958]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.212067"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.212067"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 780 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.217683"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.217683"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 781 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 781 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.224958"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.224958"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 782 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.234445"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.234445"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 783 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.240397"], ["state", "pending"], ["target_id", 783], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.240397"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 783) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:29.244177"], ["target_id", 783], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.244177"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 783 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.250332"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.250332"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 784 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (2.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.256203"], ["state", "pending"], ["target_id", 784], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.256203"]]  (3.4ms) RELEASE SAVEPOINT active_record_1  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 784 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) ROLLBACK  (0.5ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.277529"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.277529"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 785 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.282916"], ["state", "pending"], ["target_id", 785], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.282916"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 785) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:29.287064"], ["target_id", 785], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 02:11:29.287064"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 785 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 785 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.296594"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.296594"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 786 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.301519"], ["state", "pending"], ["target_id", 786], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.301519"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 786 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 786 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.309283"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.309283"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 787 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.313569"], ["state", "pending"], ["target_id", 787], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.313569"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 787) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.317119"], ["group_id", 1], ["target_id", 787], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.317119"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 787 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 787 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.324591"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.324591"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 788 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.328329"], ["state", "pending"], ["target_id", 788], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.328329"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 788) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:29.331415"], ["target_id", 788], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.331415"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 788 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 788 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.338492"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.338492"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.342876"], ["state", "pending"], ["target_id", 789], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.342876"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 965 [["group_id", 1], ["updated_at", "2015-09-07 02:11:29.346782"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.354296"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.354296"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.357660"], ["state", "pending"], ["target_id", 790], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.357660"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 966]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 790]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.365964"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.365964"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 791 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.369342"], ["state", "pending"], ["target_id", 791], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.369342"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 791) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:29.372659"], ["target_id", 791], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 02:11:29.372659"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 967]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 791]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 791 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 791 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.381017"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.381017"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 792 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.384675"], ["state", "pending"], ["target_id", 792], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.384675"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 792) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.388593"], ["group_id", 1], ["target_id", 792], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.388593"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 792 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 968]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 792]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 792 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.398988"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.398988"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 793 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.402354"], ["state", "pending"], ["target_id", 793], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.402354"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 793 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 793 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.4ms) BEGIN  (0.8ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.414736"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.414736"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 794 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.424111"], ["state", "pending"], ["target_id", 794], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.424111"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 794) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:29.427892"], ["target_id", 794], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 02:11:29.427892"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 794 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 794 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.435863"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.435863"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 795 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.1ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.439753"], ["state", "pending"], ["target_id", 795], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.439753"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (1.2ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 795) LIMIT 1 SQL (0.9ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.450852"], ["group_id", 1], ["target_id", 795], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.450852"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 795 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 795 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.462335"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.462335"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 796 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.465393"], ["state", "pending"], ["target_id", 796], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.465393"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 796 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'aGHsrsMy3HTAxJt9Sl6_LQqU7oCLbrk4lT8EGO8pzy_A' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.469039"], ["target_id", 796], ["target_type", "User"], ["token", "aGHsrsMy3HTAxJt9Sl6_LQqU7oCLbrk4lT8EGO8pzy_A"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.469039"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.474924"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.474924"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 797 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.478408"], ["state", "pending"], ["target_id", 797], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.478408"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 797 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'cCTuitt9Pj2_cLTJ3iRPTAtzgmXcPJb7vokxf_AnTcvg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.481894"], ["target_id", 797], ["target_type", "User"], ["token", "cCTuitt9Pj2_cLTJ3iRPTAtzgmXcPJb7vokxf_AnTcvg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.481894"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 797 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.488014"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.488014"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 798 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.491597"], ["state", "pending"], ["target_id", 798], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.491597"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 798 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ALoEgSubORIpKXBzpfyvrwVPrJUXbpjzBu_2SOoSfKDA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.495109"], ["target_id", 798], ["target_type", "User"], ["token", "ALoEgSubORIpKXBzpfyvrwVPrJUXbpjzBu_2SOoSfKDA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.495109"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 99 [["active", "f"], ["updated_at", "2015-09-07 02:11:29.497767"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 798 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'IWI0mW1Vz3t4j90F-7t5Ag33lfIZRFLr06knnEdyAblw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.500892"], ["target_id", 798], ["target_type", "User"], ["token", "IWI0mW1Vz3t4j90F-7t5Ag33lfIZRFLr06knnEdyAblw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.500892"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.506122"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.506122"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 799 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 799) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:29.510349"], ["target_id", 799], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.510349"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.514751"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.514751"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 800 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 800) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:29.518709"], ["target_id", 800], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.518709"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 800 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.524282"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.524282"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 801) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:29.527306"], ["target_id", 801], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.527306"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 801 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 167]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.533735"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.533735"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 802) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:29.536601"], ["target_id", 802], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-07 02:11:29.536601"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 802 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.542269"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.542269"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 803) LIMIT 1 SQL (0.5ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.545438"], ["group_id", 1], ["target_id", 803], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.545438"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 803 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 169]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.553820"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.553820"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 804) LIMIT 1 SQL (1.0ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.556875"], ["group_id", 1], ["target_id", 804], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.556875"]]  (0.7ms) RELEASE SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (1.6ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 804 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.5ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.576629"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.576629"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 805) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:29.579707"], ["target_id", 805], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.579707"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 805 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.584929"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.584929"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 806) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:29.588001"], ["target_id", 806], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.588001"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 806 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.593897"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.593897"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 807) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 02:11:29.596875"], ["target_id", 807], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.596875"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 807) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 807 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 807 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 173]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 807 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.607563"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.607563"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 808 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.612695"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.612695"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'usH2zNliTUVf7jfRNvvAxAcM6LAFSR1SduWkf49D_axA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.614493"], ["target_id", 809], ["target_type", "User"], ["token", "usH2zNliTUVf7jfRNvvAxAcM6LAFSR1SduWkf49D_axA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.614493"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'usH2zNliTUVf7jfRNvvAxAcM6LAFSR1SduWkf49D_axA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.619828"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.619828"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ziuIoTMIFlbN2JvDlQhzqwW8isnMlS1ytFoNOymxz0og' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.621829"], ["target_id", 810], ["target_type", "User"], ["token", "ziuIoTMIFlbN2JvDlQhzqwW8isnMlS1ytFoNOymxz0og"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.621829"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 102 [["active", "f"], ["updated_at", "2015-09-07 02:11:29.626311"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ziuIoTMIFlbN2JvDlQhzqwW8isnMlS1ytFoNOymxz0og' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.630805"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.630805"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'sj8XMVcob5RLekQQtHEQEwuOUPyMyjOgSP2uRwqtsNSw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.632684"], ["target_id", 811], ["target_type", "User"], ["token", "sj8XMVcob5RLekQQtHEQEwuOUPyMyjOgSP2uRwqtsNSw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.632684"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 103 [["active", "f"], ["updated_at", "2015-09-07 02:11:29.636555"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.9ms) SAVEPOINT active_record_1 SQL (1.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:29.642471"], ["email", "user@example.com"], ["updated_at", "2015-09-07 02:11:29.642471"]]  (0.8ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.8ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ZWiyUy7DjJA6XRqq687ZqgcU-EMSDIFiTVEQ5l7ogFnA' LIMIT 1 SQL (0.6ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 02:11:29.650987"], ["target_id", 812], ["target_type", "User"], ["token", "ZWiyUy7DjJA6XRqq687ZqgcU-EMSDIFiTVEQ5l7ogFnA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:29.650987"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:32.477913"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-07 02:11:32.477913"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 813 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:32.481776"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 813], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:32.481776"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 02:11:32.487512"], ["email", "2@notifyuser.com"], ["updated_at", "2015-09-07 02:11:32.487512"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 814 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 02:11:32.490441"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 814], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 02:11:32.490441"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:03.625860"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:03.625860"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.3ms) Completed 200 OK in 23ms (Views: 17.5ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:03.664420"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:03.664420"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 816 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:03.693933"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 816], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:03.693933"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 816 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 816 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 14ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:03.718081"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:03.718081"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:03.723692"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 817], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:03.723692"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 817 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 817 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:03.736529"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:03.736529"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 818 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:03.741948"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 818], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:03.741948"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 818 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:03.745108"], ["parent_id", 1], ["state", "pending"], ["target_id", 818], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:03.745108"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 818 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 818 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:03.759568"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:03.759568"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 819 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:03.765352"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 819], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:03.765352"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 819 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:03.768720"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 819], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:03.768720"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 819 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:03.772147"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 819], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:03.772147"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 819 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 168ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:03.951144"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:03.951144"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 820 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:03.959100"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 820], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:03.959100"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 820 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:03.963292"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 820], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:03.963292"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 820 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:03.967111"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 820], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:03.967111"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"984"} NotifyUser::BaseNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 820 AND "notify_user_notifications"."target_type" = 'User' AND (id = '984') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 820]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 820 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 984 [["state", "read"], ["updated_at", "2015-09-07 03:11:03.990382"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 24ms (Views: 1.9ms | ActiveRecord: 2.2ms) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 984 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.012619"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.012619"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 821 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:04.019230"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 821], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.019230"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 821 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:04.022977"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 821], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.022977"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 821 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:04.026617"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 821], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.026617"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"987"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 821 AND "notify_user_notifications"."target_type" = 'User' AND (id = '987') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 821]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 821 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 987 [["state", "read"], ["updated_at", "2015-09-07 03:11:04.036504"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.3ms | ActiveRecord: 1.7ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"987"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 821 AND "notify_user_notifications"."target_type" = 'User' AND (id = '987') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.3ms | ActiveRecord: 2.2ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.046822"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.046822"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 822 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:04.053592"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 822], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.053592"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 822 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:04.057509"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 822], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.057509"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 822 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:04.060884"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 822], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.060884"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 822 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 822 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 4ms (Views: 1.0ms | ActiveRecord: 0.9ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 822 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.074466"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.074466"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 4ms (Views: 2.1ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.094280"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.094280"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 3ms (Views: 1.8ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.110531"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.110531"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 825 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:04.117446"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 825], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.117446"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["993"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 825 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('993')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 825 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('993')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.134094"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.134094"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 826 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:04.143168"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 826], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.143168"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["994"]} SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 826 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('994')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 826 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('994')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.163681"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.163681"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 827 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:04.172047"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 827], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.172047"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 827 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 827 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 827) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:04.201291"], ["target_id", 827], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.201291"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 827 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 28ms (Views: 2.2ms | ActiveRecord: 2.0ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 827 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.214480"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.214480"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 828 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:04.220789"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 828], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.220789"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 828 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 828 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 828 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 7ms (Views: 2.7ms | ActiveRecord: 0.7ms) NotifyUser::Unsubscribe Load (0.9ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 828 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.248860"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.248860"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 829 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:04.255949"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 829], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.255949"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 829 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 829) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:04.264041"], ["target_id", 829], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.264041"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 829 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 7ms (ActiveRecord: 1.6ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.273159"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.273159"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 830 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:04.279025"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 830], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.279025"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 830) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:04.282033"], ["target_id", 830], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.282033"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 830 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 176]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 4ms (ActiveRecord: 0.9ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.295002"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.295002"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 831 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:04.300941"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 831], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.300941"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.7ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 831 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'AB6coX4fZdGnKZ0fTmN_rAQKW-0qdcEn7CZZiBQ4-xVQ' LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.312392"], ["target_id", 831], ["target_type", "User"], ["token", "AB6coX4fZdGnKZ0fTmN_rAQKW-0qdcEn7CZZiBQ4-xVQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.312392"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"AB6coX4fZdGnKZ0fTmN_rAQKW-0qdcEn7CZZiBQ4-xVQ"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'AB6coX4fZdGnKZ0fTmN_rAQKW-0qdcEn7CZZiBQ4-xVQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'AB6coX4fZdGnKZ0fTmN_rAQKW-0qdcEn7CZZiBQ4-xVQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 831]]  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 831) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:04.322908"], ["target_id", 831], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.322908"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 105 [["active", "f"], ["updated_at", "2015-09-07 03:11:04.324710"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.3ms | ActiveRecord: 2.4ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 24.0ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.1ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.7ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.605383"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.605383"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 832 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.608812"], ["state", "pending"], ["target_id", 832], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.608812"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 832 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.615191"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.615191"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 833 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.619642"], ["state", "pending"], ["target_id", 833], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.619642"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 833 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.626736"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.626736"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 834 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.630126"], ["state", "pending"], ["target_id", 834], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.630126"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 834 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.636087"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.636087"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 835 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.639279"], ["state", "pending"], ["target_id", 835], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.639279"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 835 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.646947"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.646947"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 836 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.650376"], ["state", "pending"], ["target_id", 836], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.650376"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 836 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.656928"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.656928"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 837 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.660621"], ["state", "pending"], ["target_id", 837], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.660621"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 837 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.667006"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.667006"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 838 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.670306"], ["state", "pending"], ["target_id", 838], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.670306"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.674403"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.674403"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 839 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.677689"], ["state", "pending"], ["target_id", 839], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.677689"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.681715"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.681715"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 840 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.685114"], ["state", "pending"], ["target_id", 840], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.685114"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 840 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1008 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 03:11:04.688080"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.693362"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.693362"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 841 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.696691"], ["state", "pending"], ["target_id", 841], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.696691"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 841 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1009 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 03:11:04.699982"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.705490"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.705490"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 842 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.708963"], ["state", "pending"], ["target_id", 842], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.708963"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 842 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1010 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 03:11:04.712703"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.717901"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.717901"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 843 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.721122"], ["state", "pending"], ["target_id", 843], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.721122"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 843 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1011 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 03:11:04.724195"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.729545"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.729545"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 844 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.732699"], ["state", "pending"], ["target_id", 844], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.732699"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 844 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.738473"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.738473"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 845 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.741583"], ["state", "pending"], ["target_id", 845], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.741583"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 845 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 845 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1013 [["state", "sent"], ["updated_at", "2015-09-07 03:11:04.746654"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 845 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1013 [["sent_time", "2015-09-07 03:11:04.747875"], ["updated_at", "2015-09-07 03:11:04.749286"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.754714"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.754714"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 846 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.758449"], ["state", "pending"], ["target_id", 846], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.758449"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 846 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 846 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1014)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 846 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1014 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:04.765368"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1014]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 846]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 846 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 846]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 846 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1014 [["sent_time", "2015-09-07 03:11:04.773409"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:04.776044"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 846 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1014]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 846]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 846 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 846 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 846 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '4wy9F57hpbbgAdGLxltgHwlgI1MR3KdxH6g3c6pwcLBw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.786706"], ["target_id", 846], ["target_type", "User"], ["token", "4wy9F57hpbbgAdGLxltgHwlgI1MR3KdxH6g3c6pwcLBw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.786706"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.8ms Sent mail to user@example.com (6.8ms) Date: Mon, 07 Sep 2015 13:11:04 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed0048c1d5c_1635b3ff7f086020423522@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.799984"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.799984"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 847 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.803613"], ["state", "pending_as_aggregation_parent"], ["target_id", 847], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.803613"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 847 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.807208"], ["state", "pending"], ["target_id", 847], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.807208"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 847 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 847 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1016)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.814402"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.814402"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 848 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.817736"], ["state", "pending"], ["target_id", 848], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.817736"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 848 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 848 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1017 [["state", "sent"], ["updated_at", "2015-09-07 03:11:04.821690"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 848 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1017 [["sent_time", "2015-09-07 03:11:04.822870"], ["updated_at", "2015-09-07 03:11:04.824376"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1017]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 848]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 848 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 848 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 848 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Y7p4qxY8ZZnjOWhOqZxo2ADO6bdD9zLEqn42RhBPmL-w' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.833700"], ["target_id", 848], ["target_type", "User"], ["token", "Y7p4qxY8ZZnjOWhOqZxo2ADO6bdD9zLEqn42RhBPmL-w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.833700"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.8ms Sent mail to user@example.com (1.8ms) Date: Mon, 07 Sep 2015 13:11:04 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed0048cc72a_1635b3ff7f0860204236e7@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.841309"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.841309"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 849 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.845774"], ["state", "pending"], ["target_id", 849], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.845774"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 849 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1018 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-07 03:11:04.849188"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.853564"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.853564"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 850 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.856829"], ["state", "pending"], ["target_id", 850], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.856829"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 850) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:04.859764"], ["target_id", 850], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 03:11:04.859764"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1019]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 850]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 850 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 850 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.867998"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.867998"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.871646"], ["state", "pending"], ["target_id", 851], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.871646"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1020]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 851]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.879903"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.879903"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.883373"], ["state", "pending"], ["target_id", 852], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.883373"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1021 [["state", "sent"], ["updated_at", "2015-09-07 03:11:04.897357"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1021 [["sent_time", "2015-09-07 03:11:04.898699"], ["updated_at", "2015-09-07 03:11:04.900379"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1021]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 852]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 852 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ISqOW8fRkO5QG1bGOheDMAjg6USPuKdeIQdg4JPEhMDg' LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.909487"], ["target_id", 852], ["target_type", "User"], ["token", "ISqOW8fRkO5QG1bGOheDMAjg6USPuKdeIQdg4JPEhMDg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.909487"]]  (0.8ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 9.7ms Sent mail to user@example.com (3.7ms) Date: Mon, 07 Sep 2015 13:11:04 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed0048e024c_1635b3ff7f086020423799@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.6ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.925453"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.925453"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 853 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.929310"], ["state", "pending"], ["target_id", 853], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.929310"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1022]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 853]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 853 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 853 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.939461"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.939461"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 854 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.942929"], ["state", "pending"], ["target_id", 854], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.942929"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1023]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 854]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 854 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 854]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 854 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1023 [["sent_time", "2015-09-07 03:11:04.948025"], ["state", "sent"], ["updated_at", "2015-09-07 03:11:04.950468"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 854 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.956999"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.956999"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 855 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.960215"], ["state", "pending"], ["target_id", 855], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.960215"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 855 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.963615"], ["state", "pending"], ["target_id", 855], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.963615"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1025]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 855]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 855 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 855]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 855 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1025 [["sent_time", "2015-09-07 03:11:04.968237"], ["state", "sent"], ["updated_at", "2015-09-07 03:11:04.970737"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 855]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 855 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1024 [["sent_time", "2015-09-07 03:11:04.973251"], ["state", "sent"], ["updated_at", "2015-09-07 03:11:04.976659"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 855 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 855 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.985632"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.985632"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 856 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:04.988909"], ["state", "read"], ["target_id", 856], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:04.988909"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1026]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 856]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 856 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:04.996906"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:04.996906"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 857 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 857 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.001241"], ["group_id", 2], ["state", "pending"], ["target_id", 857], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.001241"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1027]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 857]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 857 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 857]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 857 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 857 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1027 [["sent_time", "2015-09-07 03:11:05.006920"], ["state", "sent"], ["updated_at", "2015-09-07 03:11:05.010409"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 857 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 857 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1027]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 857]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 857 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 857 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 857 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 857 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'GQ1d4F8_1A9m7U-Wt8TMOgPjmHq3QCo4SHP5l_Ogbn0Q' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.022954"], ["target_id", 857], ["target_type", "User"], ["token", "GQ1d4F8_1A9m7U-Wt8TMOgPjmHq3QCo4SHP5l_Ogbn0Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.022954"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.5ms Sent mail to user@example.com (2.7ms) Date: Mon, 07 Sep 2015 13:11:05 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed00496cc4_1635b3ff7f086020423896@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.032650"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.032650"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 858 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 858 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.037366"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 858], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.037366"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 858 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 858 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1028 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.041583"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 858 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 858 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1028 [["sent_time", "2015-09-07 03:11:05.042690"], ["updated_at", "2015-09-07 03:11:05.045158"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1028]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.052063"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.052063"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 859 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 859 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.056689"], ["group_id", 1], ["state", "pending"], ["target_id", 859], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.056689"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 859 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1029) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.062296"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.062296"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 860 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 860 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.067155"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 860], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.067155"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 860 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 860 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.073007"], ["group_id", 1], ["state", "pending"], ["target_id", 860], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.073007"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 860 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1031) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.078847"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.078847"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 861 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 861 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.083425"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 861], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.083425"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 861 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 861 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.088207"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 861], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.088207"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 861 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 861 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.092259"], ["group_id", 1], ["state", "pending"], ["target_id", 861], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.092259"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 861 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1034) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.098184"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.098184"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 862 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 862 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.102871"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 862], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.102871"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 862 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 862 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.122020"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 862], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.122020"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 862 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 862 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.0ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.130963"], ["group_id", 1], ["state", "pending"], ["target_id", 862], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.130963"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 862 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1037) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.142256"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.142256"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 863 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 863 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.149588"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 863], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.149588"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 863 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 863 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.157632"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 863], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.157632"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 863 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 863 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.164620"], ["group_id", 1], ["state", "pending"], ["target_id", 863], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.164620"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 863 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1040) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.175862"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.175862"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 864 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 864 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 17:11:05.177848"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 864], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.184641"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 864 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 03:11:05.188336') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 864 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 03:11:05.188336') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 864 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 864 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 03:11:05.195287"], ["group_id", 1], ["parent_id", 1041], ["state", "pending"], ["target_id", 864], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.195287"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.200490"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.200490"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 865 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 865 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 02:11:05.201616"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 865], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.205184"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 865 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 03:11:05.207467')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 865 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 865 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.211731"], ["group_id", 1], ["state", "pending"], ["target_id", 865], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.211731"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.216213"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.216213"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 866 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 866 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 02:11:05.217635"], ["group_id", 1], ["state", "pending"], ["target_id", 866], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.221393"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 866 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 03:11:05.223976')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 866 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 866 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.228196"], ["group_id", 1], ["state", "pending"], ["target_id", 866], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.228196"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.233494"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.233494"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 867 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 867 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.238484"], ["group_id", 1], ["state", "pending"], ["target_id", 867], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.238484"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 867 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1047) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 867 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1047) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.248017"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.248017"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 868 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 868 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.252546"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 868], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.252546"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 868 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 868 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1048 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.256689"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 868 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 868 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1048 [["sent_time", "2015-09-07 03:11:05.258020"], ["updated_at", "2015-09-07 03:11:05.260698"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 868 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 868 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.265280"], ["group_id", 1], ["state", "pending"], ["target_id", 868], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.265280"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 868 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1049) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 868 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1049) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.273607"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.273607"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.278439"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 869], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.278439"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1050 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.283482"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1050 [["sent_time", "2015-09-07 03:11:05.284805"], ["updated_at", "2015-09-07 03:11:05.288246"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.293494"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 869], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.293494"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1051 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.298712"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1051 [["sent_time", "2015-09-07 03:11:05.300274"], ["updated_at", "2015-09-07 03:11:05.303027"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.308088"], ["group_id", 1], ["state", "pending"], ["target_id", 869], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.308088"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 869 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1052) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 869 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1052) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.316607"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.316607"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.321519"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 870], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.321519"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1053 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.325900"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1053 [["sent_time", "2015-09-07 03:11:05.327105"], ["updated_at", "2015-09-07 03:11:05.329836"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.334611"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 870], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.334611"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1054 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.339427"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1054 [["sent_time", "2015-09-07 03:11:05.340874"], ["updated_at", "2015-09-07 03:11:05.343700"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.348496"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 870], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.348496"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1055 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.353816"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1055 [["sent_time", "2015-09-07 03:11:05.355282"], ["updated_at", "2015-09-07 03:11:05.357983"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.362671"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 870], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.362671"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1056 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.366805"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1056 [["sent_time", "2015-09-07 03:11:05.368049"], ["updated_at", "2015-09-07 03:11:05.370556"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.375303"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 870], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.375303"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1057 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.379553"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1057 [["sent_time", "2015-09-07 03:11:05.380703"], ["updated_at", "2015-09-07 03:11:05.383096"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.387684"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 870], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.387684"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1058 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.391775"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1058 [["sent_time", "2015-09-07 03:11:05.393020"], ["updated_at", "2015-09-07 03:11:05.395404"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.400002"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 870], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.400002"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1059 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.404154"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1059 [["sent_time", "2015-09-07 03:11:05.405321"], ["updated_at", "2015-09-07 03:11:05.407810"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.412529"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 870], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.412529"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1060 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.417255"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1060 [["sent_time", "2015-09-07 03:11:05.418505"], ["updated_at", "2015-09-07 03:11:05.421098"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.425610"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 870], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.425610"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1061 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.429929"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1061 [["sent_time", "2015-09-07 03:11:05.431127"], ["updated_at", "2015-09-07 03:11:05.433648"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.438344"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 870], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.438344"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1062 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.442513"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1062 [["sent_time", "2015-09-07 03:11:05.443755"], ["updated_at", "2015-09-07 03:11:05.446676"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.452959"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 870], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.452959"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1063 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.458068"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1063 [["sent_time", "2015-09-07 03:11:05.459946"], ["updated_at", "2015-09-07 03:11:05.464268"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.469642"], ["group_id", 1], ["state", "pending"], ["target_id", 870], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.469642"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 870 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1064) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 870 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1064) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.478038"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.478038"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 871 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 871 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.482631"], ["group_id", 1], ["state", "pending"], ["target_id", 871], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.482631"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 871 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 871 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 871 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1065)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 871 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 871 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1065 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.493731"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.498517"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.498517"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 872 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 872 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.503017"], ["group_id", 1], ["state", "pending"], ["target_id", 872], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.503017"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 872 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 872 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 872 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1066)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 872 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 872 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1066 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.511415"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.516490"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.516490"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 873 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 873 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.522363"], ["group_id", 1], ["state", "pending"], ["target_id", 873], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.522363"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 873 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 873 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 873 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1067)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 873 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 873 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1067 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.531491"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1067]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.537623"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.537623"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 874 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 874 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.542106"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 874], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.542106"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 874 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 874 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:13:05.542106"], ["group_id", 1], ["state", "pending"], ["target_id", 874], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.546779"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 874 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 874 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 874 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1069)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 874 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 874 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1069 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 03:11:05.555111"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.560693"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.560693"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 875 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 875 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.565626"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 875], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.565626"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 875 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 03:11:05.568001') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 875 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 03:11:05.568001') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 875 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 875 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 03:13:05.565626"], ["group_id", 1], ["parent_id", 1070], ["state", "pending"], ["target_id", 875], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.573428"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1071]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.578682"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.578682"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 876 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 876 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.582837"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 876], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.582837"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 876 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 876 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.586839"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 876], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.586839"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 876 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 876 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.591018"], ["group_id", 1], ["state", "pending"], ["target_id", 876], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.591018"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 876 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 876 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 876 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1074)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.599647"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.599647"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 877 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 877 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.605272"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 877], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.605272"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 877 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 877 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.609857"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 877], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.609857"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 877 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 877 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:05.613964"], ["group_id", 1], ["state", "pending"], ["target_id", 877], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.613964"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 877 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 877 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 877 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1077) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1077]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.623247"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.623247"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 878 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.628729"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.628729"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 879 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 879 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.635205"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.635205"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 880 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.641134"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.641134"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 881 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.645281"], ["state", "pending"], ["target_id", 881], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.645281"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 881) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:05.648671"], ["target_id", 881], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.648671"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 881 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.653661"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.653661"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 882 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.656779"], ["state", "pending"], ["target_id", 882], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.656779"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 882 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.661612"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.661612"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 883 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.665215"], ["state", "pending"], ["target_id", 883], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.665215"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 883) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:05.669357"], ["target_id", 883], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 03:11:05.669357"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 883 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 883 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.675316"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.675316"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 884 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.678808"], ["state", "pending"], ["target_id", 884], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.678808"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 884 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 884 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.685429"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.685429"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 885 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.689366"], ["state", "pending"], ["target_id", 885], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.689366"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 885) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.692222"], ["group_id", 1], ["target_id", 885], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.692222"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 885 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 885 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.699464"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.699464"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 886 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.702592"], ["state", "pending"], ["target_id", 886], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.702592"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 886) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:05.705389"], ["target_id", 886], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.705389"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 886 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 886 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.712145"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.712145"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 887 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.715228"], ["state", "pending"], ["target_id", 887], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.715228"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 887 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 887 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1084 [["group_id", 1], ["updated_at", "2015-09-07 03:11:05.718956"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 887 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 887 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.727044"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.727044"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 888 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.731189"], ["state", "pending"], ["target_id", 888], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.731189"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1085]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 888]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 888 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 888 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.739216"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.739216"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 889 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.742462"], ["state", "pending"], ["target_id", 889], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.742462"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 889) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:05.745480"], ["target_id", 889], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 03:11:05.745480"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1086]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 889]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 889 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 889 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.753442"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.753442"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 890 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.756642"], ["state", "pending"], ["target_id", 890], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.756642"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 890) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.759741"], ["group_id", 1], ["target_id", 890], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.759741"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 890 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1087]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 890]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 890 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.770371"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.770371"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 891 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.773795"], ["state", "pending"], ["target_id", 891], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.773795"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 891 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 891 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.780749"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.780749"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 892 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.784130"], ["state", "pending"], ["target_id", 892], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.784130"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.9ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 892) LIMIT 1 SQL (1.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:05.789130"], ["target_id", 892], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 03:11:05.789130"]]  (1.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 892 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 892 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.6ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.808629"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.808629"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 893 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.814573"], ["state", "pending"], ["target_id", 893], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.814573"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 893) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.817684"], ["group_id", 1], ["target_id", 893], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.817684"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 893 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 893 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.826022"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.826022"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 894 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.829295"], ["state", "pending"], ["target_id", 894], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.829295"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 894 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ZMQz6meSaaAGVFM_oZlojgIlcw2CRcMDoUhQf-IqCd3A' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.832554"], ["target_id", 894], ["target_type", "User"], ["token", "ZMQz6meSaaAGVFM_oZlojgIlcw2CRcMDoUhQf-IqCd3A"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.832554"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.837091"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.837091"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 895 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.840696"], ["state", "pending"], ["target_id", 895], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.840696"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 895 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'bcJu6uInUDsYmgc2Y8jTXgqEdIKJKCtt2kFVaZ06hdqQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.844256"], ["target_id", 895], ["target_type", "User"], ["token", "bcJu6uInUDsYmgc2Y8jTXgqEdIKJKCtt2kFVaZ06hdqQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.844256"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 895 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.850298"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.850298"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 896 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.853705"], ["state", "pending"], ["target_id", 896], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.853705"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 896 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ArRxrD3vqQFWn4GYr67pSQzehI6Es4lbMzQD1jCpoFNg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.856803"], ["target_id", 896], ["target_type", "User"], ["token", "ArRxrD3vqQFWn4GYr67pSQzehI6Es4lbMzQD1jCpoFNg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.856803"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 112 [["active", "f"], ["updated_at", "2015-09-07 03:11:05.859328"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 896 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '43WkQAi2Zoy3nz9kBUiFDQkfLZDgX9YVFQ6gc14jnF1w' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.862488"], ["target_id", 896], ["target_type", "User"], ["token", "43WkQAi2Zoy3nz9kBUiFDQkfLZDgX9YVFQ6gc14jnF1w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.862488"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.867491"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.867491"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.6ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 897 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 897) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:05.872411"], ["target_id", 897], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.872411"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.876114"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.876114"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 898 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 898) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:05.879818"], ["target_id", 898], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.879818"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 898 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.7ms) BEGIN  (0.8ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.888922"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.888922"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (1.7ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 899) LIMIT 1 SQL (0.7ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:05.900211"], ["target_id", 899], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.900211"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (1.0ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 899 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 189]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.912190"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.912190"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 900) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:05.915086"], ["target_id", 900], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-07 03:11:05.915086"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 900 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.920169"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.920169"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 901) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.923040"], ["group_id", 1], ["target_id", 901], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.923040"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 901 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 191]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.929446"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.929446"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 902) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.932222"], ["group_id", 1], ["target_id", 902], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.932222"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 902 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.937330"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.937330"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 903) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:05.940071"], ["target_id", 903], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.940071"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 903 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.945110"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.945110"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 904) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:05.948399"], ["target_id", 904], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.948399"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 904 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.954872"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.954872"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 905) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 03:11:05.958424"], ["target_id", 905], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.958424"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 905) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 905 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 905 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 195]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 905 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.969197"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.969197"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 906 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.973931"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.973931"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'bo-WDWHHZBE1zCnNYfc23w61BeiSOJD0-ay5DrmmtaEA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.975910"], ["target_id", 907], ["target_type", "User"], ["token", "bo-WDWHHZBE1zCnNYfc23w61BeiSOJD0-ay5DrmmtaEA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.975910"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'bo-WDWHHZBE1zCnNYfc23w61BeiSOJD0-ay5DrmmtaEA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.981416"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.981416"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ahwpIYKWl-xNBRX5wuU0AAvIlLcf4-5EEBNMX9WNM4Gg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.983243"], ["target_id", 908], ["target_type", "User"], ["token", "ahwpIYKWl-xNBRX5wuU0AAvIlLcf4-5EEBNMX9WNM4Gg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.983243"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 115 [["active", "f"], ["updated_at", "2015-09-07 03:11:05.986318"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ahwpIYKWl-xNBRX5wuU0AAvIlLcf4-5EEBNMX9WNM4Gg' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.990193"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.990193"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.6ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'NcRIsoR3mLRGrw5hoPccGwVn6RBvnq6YgfTIKN7S_nSg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:05.992177"], ["target_id", 909], ["target_type", "User"], ["token", "NcRIsoR3mLRGrw5hoPccGwVn6RBvnq6YgfTIKN7S_nSg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:05.992177"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 116 [["active", "f"], ["updated_at", "2015-09-07 03:11:05.996528"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:05.999468"], ["email", "user@example.com"], ["updated_at", "2015-09-07 03:11:05.999468"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '1FxqJJz5pgc9HcJ4mmRoEw3AX_DBBhbRBIWbnIQjxZ_A' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 03:11:06.001361"], ["target_id", 910], ["target_type", "User"], ["token", "1FxqJJz5pgc9HcJ4mmRoEw3AX_DBBhbRBIWbnIQjxZ_A"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:06.001361"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:06.007200"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-07 03:11:06.007200"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 911 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:06.010207"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 911], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:06.010207"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 03:11:06.015102"], ["email", "2@notifyuser.com"], ["updated_at", "2015-09-07 03:11:06.015102"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 912 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 03:11:06.018162"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 912], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 03:11:06.018162"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.8ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:51.949962"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:51.949962"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.3ms) Completed 200 OK in 21ms (Views: 15.9ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:51.988154"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:51.988154"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 914 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.015490"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 914], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.015490"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (1.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 914 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 914 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 15ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.039723"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.039723"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 915 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.045442"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 915], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.045442"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 915 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 915 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.059100"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.059100"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 916 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.064932"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 916], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.064932"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 916 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.068447"], ["parent_id", 1], ["state", "pending"], ["target_id", 916], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.068447"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 916 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 916 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 8ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.085461"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.085461"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 917 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.091072"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 917], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.091072"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 917 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.094919"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 917], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.094919"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 917 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.098679"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 917], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.098679"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 917 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 149ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.259820"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.259820"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 918 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.267952"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 918], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.267952"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 918 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.271963"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 918], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.271963"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 918 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.276010"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 918], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.276010"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1103"} NotifyUser::BaseNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 918 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1103') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 918]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 918 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1103 [["state", "read"], ["updated_at", "2015-09-07 04:23:52.295388"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 21ms (Views: 1.9ms | ActiveRecord: 2.0ms) NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 1103 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.316167"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.316167"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 919 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.322684"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 919], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.322684"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 919 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.326528"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 919], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.326528"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 919 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.330115"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 919], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.330115"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1106"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 919 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1106') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 919]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 919 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1106 [["state", "read"], ["updated_at", "2015-09-07 04:23:52.340211"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.3ms | ActiveRecord: 1.6ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1106"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 919 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1106') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.2ms | ActiveRecord: 2.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.351248"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.351248"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 920 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.357778"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 920], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.357778"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 920 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.364063"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 920], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.364063"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 920 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.367708"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 920], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.367708"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.7ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 920 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 920 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 4ms (Views: 0.8ms | ActiveRecord: 1.1ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 920 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.381796"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.381796"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 5ms (Views: 3.1ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.402697"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.402697"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 3ms (Views: 2.0ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.420319"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.420319"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 923 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.427480"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 923], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.427480"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["1112"]} SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 923 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1112')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 923 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1112')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.443462"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.443462"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 924 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.451495"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 924], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.451495"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["1113"]} SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 924 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1113')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 924 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1113')) Completed 500 Internal Server Error in 8ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.471703"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.471703"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 925 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.480956"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 925], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.480956"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 925 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 925 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 925) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:52.504401"], ["target_id", 925], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.504401"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 925 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 24ms (Views: 3.4ms | ActiveRecord: 1.9ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 925 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.518197"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.518197"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 926 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.524804"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 926], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.524804"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 926 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 926 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 926 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 6ms (Views: 2.1ms | ActiveRecord: 0.8ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 926 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.554513"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.554513"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 927 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.562729"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 927], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.562729"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 927 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 927) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:52.570416"], ["target_id", 927], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.570416"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 927 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 7ms (ActiveRecord: 1.7ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.580204"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.580204"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 928 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.586782"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 928], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.586782"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 928) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:52.589914"], ["target_id", 928], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.589914"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 928 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 198]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 4ms (ActiveRecord: 0.9ms) NotifyUser::Unsubscribe Load (0.2ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.602746"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.602746"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 929 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:52.609264"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 929], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.609264"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.7ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 929 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'UVVGctGdR8fYxy7hXIjedQuUNWexzkqr6yew-B9KwiXQ' LIMIT 1 SQL (1.1ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:52.621315"], ["target_id", 929], ["target_type", "User"], ["token", "UVVGctGdR8fYxy7hXIjedQuUNWexzkqr6yew-B9KwiXQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.621315"]]  (0.4ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"UVVGctGdR8fYxy7hXIjedQuUNWexzkqr6yew-B9KwiXQ"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'UVVGctGdR8fYxy7hXIjedQuUNWexzkqr6yew-B9KwiXQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'UVVGctGdR8fYxy7hXIjedQuUNWexzkqr6yew-B9KwiXQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 929]]  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 929) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:52.633552"], ["target_id", 929], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.633552"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 118 [["active", "f"], ["updated_at", "2015-09-07 04:23:52.635303"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.3ms | ActiveRecord: 2.3ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 29.9ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.2ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.7ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.924134"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.924134"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 930 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:52.927430"], ["state", "pending"], ["target_id", 930], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.927430"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 930 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.933833"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.933833"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 931 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:52.937320"], ["state", "pending"], ["target_id", 931], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.937320"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 931 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.944946"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.944946"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 932 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:52.948548"], ["state", "pending"], ["target_id", 932], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.948548"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 932 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.956458"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.956458"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 933 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:52.959949"], ["state", "pending"], ["target_id", 933], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.959949"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 933 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.966244"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.966244"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 934 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:52.969518"], ["state", "pending"], ["target_id", 934], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.969518"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 934 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.975135"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.975135"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 935 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:52.978726"], ["state", "pending"], ["target_id", 935], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.978726"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.982606"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.982606"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 936 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:52.985645"], ["state", "pending"], ["target_id", 936], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.985645"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:52.989303"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:52.989303"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 937 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:52.995038"], ["state", "pending"], ["target_id", 937], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:52.995038"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 937 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1126 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 04:23:52.998269"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.003866"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.003866"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 938 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.007482"], ["state", "pending"], ["target_id", 938], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.007482"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 938 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1127 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 04:23:53.010645"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.015735"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.015735"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 939 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.018940"], ["state", "pending"], ["target_id", 939], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.018940"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 939 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1128 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 04:23:53.021771"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.027571"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.027571"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 940 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.031065"], ["state", "pending"], ["target_id", 940], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.031065"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 940 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1129 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 04:23:53.034095"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.039259"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.039259"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 941 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.045074"], ["state", "pending"], ["target_id", 941], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.045074"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 941 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.051141"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.051141"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 942 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.054501"], ["state", "pending"], ["target_id", 942], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.054501"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 942 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 942 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1131 [["state", "sent"], ["updated_at", "2015-09-07 04:23:53.059187"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 942 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1131 [["sent_time", "2015-09-07 04:23:53.060360"], ["updated_at", "2015-09-07 04:23:53.061734"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.066498"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.066498"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 943 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.069861"], ["state", "pending"], ["target_id", 943], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.069861"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 943 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 943 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1132)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 943 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1132 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.075819"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1132]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 943]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 943 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 943]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 943 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1132 [["sent_time", "2015-09-07 04:23:53.084541"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.087281"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 943 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1132]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 943]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 943 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 943 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 943 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '56wBvztyIbH-xsbi0yvlyg1Y8XNaEeXRdqMxbW4EaTeA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.099453"], ["target_id", 943], ["target_type", "User"], ["token", "56wBvztyIbH-xsbi0yvlyg1Y8XNaEeXRdqMxbW4EaTeA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.099453"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.7ms Sent mail to user@example.com (6.3ms) Date: Mon, 07 Sep 2015 14:23:53 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed115919e8d_17deb3fd689c601fc96998@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.111973"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.111973"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 944 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.115065"], ["state", "pending_as_aggregation_parent"], ["target_id", 944], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.115065"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 944 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.118871"], ["state", "pending"], ["target_id", 944], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.118871"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 944 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 944 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1134)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.126045"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.126045"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 945 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.129319"], ["state", "pending"], ["target_id", 945], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.129319"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 945 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 945 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1135 [["state", "sent"], ["updated_at", "2015-09-07 04:23:53.133323"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 945 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1135 [["sent_time", "2015-09-07 04:23:53.134419"], ["updated_at", "2015-09-07 04:23:53.135798"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1135]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 945]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 945 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 945 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 945 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '3yjZXo9LQkrbd__KVfzEfgCX6GK4HqSODbPatu-Nj7KA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.144728"], ["target_id", 945], ["target_type", "User"], ["token", "3yjZXo9LQkrbd__KVfzEfgCX6GK4HqSODbPatu-Nj7KA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.144728"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.0ms Sent mail to user@example.com (1.6ms) Date: Mon, 07 Sep 2015 14:23:53 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed1159243c6_17deb3fd689c601fc970cb@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.152113"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.152113"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 946 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.155221"], ["state", "pending"], ["target_id", 946], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.155221"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 946 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1136 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-07 04:23:53.159966"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.164215"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.164215"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 947 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.167458"], ["state", "pending"], ["target_id", 947], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.167458"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 947) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:53.170364"], ["target_id", 947], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 04:23:53.170364"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1137]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 947]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 947 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 947 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.178224"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.178224"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 948 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.181303"], ["state", "pending"], ["target_id", 948], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.181303"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1138]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 948]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 948 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 948 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.189987"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.189987"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 949 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.194896"], ["state", "pending"], ["target_id", 949], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.194896"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 949 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 949 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1139 [["state", "sent"], ["updated_at", "2015-09-07 04:23:53.199498"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 949 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1139 [["sent_time", "2015-09-07 04:23:53.200737"], ["updated_at", "2015-09-07 04:23:53.202187"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1139]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 949]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 949 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 949 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 949 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'LxoxFdRrG3JK-w7zx_d0egQTzZ8OILP7wZUo0dmvH6mQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.212902"], ["target_id", 949], ["target_type", "User"], ["token", "LxoxFdRrG3JK-w7zx_d0egQTzZ8OILP7wZUo0dmvH6mQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.212902"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 7.2ms Sent mail to user@example.com (1.9ms) Date: Mon, 07 Sep 2015 14:23:53 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed115934e3d_17deb3fd689c601fc971ce@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.221058"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.221058"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 950 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.224671"], ["state", "pending"], ["target_id", 950], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.224671"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1140]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 950]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 950 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 950 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.232983"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.232983"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 951 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.236159"], ["state", "pending"], ["target_id", 951], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.236159"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1141]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 951]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 951 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 951]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 951 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1141 [["sent_time", "2015-09-07 04:23:53.240652"], ["state", "sent"], ["updated_at", "2015-09-07 04:23:53.243009"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 951 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.249222"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.249222"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 952 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.252764"], ["state", "pending"], ["target_id", 952], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.252764"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 952 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.256701"], ["state", "pending"], ["target_id", 952], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.256701"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1143]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 952]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 952 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 952]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 952 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1143 [["sent_time", "2015-09-07 04:23:53.263696"], ["state", "sent"], ["updated_at", "2015-09-07 04:23:53.266231"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 952]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 952 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1142 [["sent_time", "2015-09-07 04:23:53.268068"], ["state", "sent"], ["updated_at", "2015-09-07 04:23:53.270588"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 952 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 952 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.278765"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.278765"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 953 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.281940"], ["state", "read"], ["target_id", 953], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.281940"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1144]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 953]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 953 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.289672"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.289672"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.294185"], ["group_id", 2], ["state", "pending"], ["target_id", 954], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.294185"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1145]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 954]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 954 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 954]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1145 [["sent_time", "2015-09-07 04:23:53.299125"], ["state", "sent"], ["updated_at", "2015-09-07 04:23:53.302865"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1145]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 954]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 954 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'o89vkgET_S3jMjrzfipSaQcUZv6rudIzrHolUuB-0VZQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.315971"], ["target_id", 954], ["target_type", "User"], ["token", "o89vkgET_S3jMjrzfipSaQcUZv6rudIzrHolUuB-0VZQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.315971"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.5ms Sent mail to user@example.com (1.8ms) Date: Mon, 07 Sep 2015 14:23:53 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed11594df84_17deb3fd689c601fc9726@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.323272"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.323272"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 955 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 955 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.330314"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 955], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.330314"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 955 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 955 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1146 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.335513"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 955 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 955 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1146 [["sent_time", "2015-09-07 04:23:53.336737"], ["updated_at", "2015-09-07 04:23:53.339418"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1146]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.346763"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.346763"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 956 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 956 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.351045"], ["group_id", 1], ["state", "pending"], ["target_id", 956], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.351045"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 956 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1147) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.356558"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.356558"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 957 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 957 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.361678"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 957], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.361678"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 957 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 957 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.366271"], ["group_id", 1], ["state", "pending"], ["target_id", 957], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.366271"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 957 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1149) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.371984"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.371984"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 958 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 958 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.378748"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 958], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.378748"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 958 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 958 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.383351"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 958], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.383351"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 958 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 958 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.388997"], ["group_id", 1], ["state", "pending"], ["target_id", 958], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.388997"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 958 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1152) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.395154"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.395154"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 959 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 959 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.399629"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 959], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.399629"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 959 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 959 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.403838"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 959], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.403838"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 959 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 959 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.407948"], ["group_id", 1], ["state", "pending"], ["target_id", 959], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.407948"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 959 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1155) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.414124"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.414124"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 960 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 960 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.430643"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 960], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.430643"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 960 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 960 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.435722"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 960], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.435722"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 960 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 960 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.440849"], ["group_id", 1], ["state", "pending"], ["target_id", 960], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.440849"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 960 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1158) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.447281"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.447281"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 961 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 961 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 18:23:53.448476"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 961], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.451924"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 961 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 04:23:53.454057') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 961 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 04:23:53.454057') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 961 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 961 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 04:23:53.459485"], ["group_id", 1], ["parent_id", 1159], ["state", "pending"], ["target_id", 961], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.459485"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.464242"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.464242"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 962 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 962 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 03:23:53.465406"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 962], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.468796"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 962 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 04:23:53.470864')  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 962 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 962 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.477579"], ["group_id", 1], ["state", "pending"], ["target_id", 962], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.477579"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.482423"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.482423"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 963 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 963 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 03:23:53.483618"], ["group_id", 1], ["state", "pending"], ["target_id", 963], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.487345"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 963 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 04:23:53.489857')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 963 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 963 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.494117"], ["group_id", 1], ["state", "pending"], ["target_id", 963], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.494117"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.498566"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.498566"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 964 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 964 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.503267"], ["group_id", 1], ["state", "pending"], ["target_id", 964], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.503267"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 964 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1165) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 964 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1165) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.511432"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.511432"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 965 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 965 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.516500"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 965], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.516500"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 965 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 965 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1166 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.520969"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 965 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 965 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1166 [["sent_time", "2015-09-07 04:23:53.522297"], ["updated_at", "2015-09-07 04:23:53.526548"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 965 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 965 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.532340"], ["group_id", 1], ["state", "pending"], ["target_id", 965], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.532340"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 965 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1167) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 965 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1167) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.540922"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.540922"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.545804"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 966], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.545804"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1168 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.550179"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1168 [["sent_time", "2015-09-07 04:23:53.551456"], ["updated_at", "2015-09-07 04:23:53.554121"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.558842"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 966], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.558842"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1169 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.563049"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1169 [["sent_time", "2015-09-07 04:23:53.564264"], ["updated_at", "2015-09-07 04:23:53.566803"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.571528"], ["group_id", 1], ["state", "pending"], ["target_id", 966], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.571528"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 966 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1170) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 966 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1170) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.580352"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.580352"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.585305"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 967], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.585305"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1171 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.589614"]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1171 [["sent_time", "2015-09-07 04:23:53.590803"], ["updated_at", "2015-09-07 04:23:53.595898"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.601236"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 967], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.601236"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1172 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.605720"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1172 [["sent_time", "2015-09-07 04:23:53.607065"], ["updated_at", "2015-09-07 04:23:53.609610"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.614324"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 967], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.614324"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1173 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.618660"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1173 [["sent_time", "2015-09-07 04:23:53.619886"], ["updated_at", "2015-09-07 04:23:53.622653"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.627598"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 967], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.627598"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1174 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.632606"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1174 [["sent_time", "2015-09-07 04:23:53.633909"], ["updated_at", "2015-09-07 04:23:53.636303"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.9ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.640885"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 967], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.640885"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1175 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.647486"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1175 [["sent_time", "2015-09-07 04:23:53.648777"], ["updated_at", "2015-09-07 04:23:53.651503"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.656178"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 967], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.656178"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1176 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.660279"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1176 [["sent_time", "2015-09-07 04:23:53.661546"], ["updated_at", "2015-09-07 04:23:53.664002"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.668335"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 967], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.668335"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1177 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.672486"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1177 [["sent_time", "2015-09-07 04:23:53.673611"], ["updated_at", "2015-09-07 04:23:53.676052"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.680544"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 967], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.680544"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1178 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.684831"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1178 [["sent_time", "2015-09-07 04:23:53.686027"], ["updated_at", "2015-09-07 04:23:53.688438"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.692802"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 967], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.692802"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1179 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.696878"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1179 [["sent_time", "2015-09-07 04:23:53.698020"], ["updated_at", "2015-09-07 04:23:53.700438"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.704911"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 967], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.704911"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1180 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.709220"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1180 [["sent_time", "2015-09-07 04:23:53.710466"], ["updated_at", "2015-09-07 04:23:53.713029"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.717423"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 967], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.717423"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1181 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.721404"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1181 [["sent_time", "2015-09-07 04:23:53.722460"], ["updated_at", "2015-09-07 04:23:53.724904"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.729262"], ["group_id", 1], ["state", "pending"], ["target_id", 967], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.729262"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 967 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1182) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 967 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1182) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.737793"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.737793"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 968 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 968 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.742163"], ["group_id", 1], ["state", "pending"], ["target_id", 968], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.742163"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 968 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 968 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 968 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1183)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 968 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 968 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1183 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.753561"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.758470"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.758470"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 969 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 969 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.763077"], ["group_id", 1], ["state", "pending"], ["target_id", 969], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.763077"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 969 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 969 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 969 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1184)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 969 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 969 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1184 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.771844"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.779165"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.779165"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 970 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 970 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.784088"], ["group_id", 1], ["state", "pending"], ["target_id", 970], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.784088"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 970 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 970 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 970 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1185)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 970 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 970 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1185 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.792051"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1185]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.798011"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.798011"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 971 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 971 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.804340"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 971], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.804340"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 971 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 971 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:25:53.804340"], ["group_id", 1], ["state", "pending"], ["target_id", 971], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.811776"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 971 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 971 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 971 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1187)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 971 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 971 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1187 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 04:23:53.821673"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.5ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.828629"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.828629"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 972 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 972 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.833722"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 972], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.833722"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 972 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 04:23:53.835919') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 972 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 04:23:53.835919') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 972 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 972 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 04:25:53.833722"], ["group_id", 1], ["parent_id", 1188], ["state", "pending"], ["target_id", 972], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.841453"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1189]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.846875"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.846875"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 973 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 973 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.851607"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 973], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.851607"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 973 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 973 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.856075"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 973], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.856075"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 973 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 973 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.860205"], ["group_id", 1], ["state", "pending"], ["target_id", 973], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.860205"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 973 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 973 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 973 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1192)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.868892"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.868892"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 974 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 974 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.873624"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 974], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.873624"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 974 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 974 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.879872"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 974], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.879872"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 974 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 974 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:53.884215"], ["group_id", 1], ["state", "pending"], ["target_id", 974], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.884215"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 974 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 974 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 974 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1195) NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1195]]  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.895408"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.895408"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 975 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.905057"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.905057"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 976 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 976 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.913491"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.913491"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 977 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.919340"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.919340"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 978 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.922799"], ["state", "pending"], ["target_id", 978], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.922799"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 978) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:53.925995"], ["target_id", 978], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.925995"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 978 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) ROLLBACK  (0.1ms) BEGIN  (0.6ms) SAVEPOINT active_record_1 SQL (0.8ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.937662"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.937662"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 979 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.945819"], ["state", "pending"], ["target_id", 979], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.945819"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 979 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.956426"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.956426"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 980 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.959874"], ["state", "pending"], ["target_id", 980], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.959874"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 980) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:53.962798"], ["target_id", 980], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 04:23:53.962798"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 980 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 980 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.968635"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.968635"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 981 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.971714"], ["state", "pending"], ["target_id", 981], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.971714"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 981 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 981 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.978091"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.978091"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 982 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.981426"], ["state", "pending"], ["target_id", 982], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.981426"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 982) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.984732"], ["group_id", 1], ["target_id", 982], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.984732"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 982 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 982 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:53.994677"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:53.994677"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 983 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:53.998423"], ["state", "pending"], ["target_id", 983], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:53.998423"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 983) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:54.002248"], ["target_id", 983], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.002248"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 983 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 983 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.008925"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.008925"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 984 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.012058"], ["state", "pending"], ["target_id", 984], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.012058"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 984 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 984 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1202 [["group_id", 1], ["updated_at", "2015-09-07 04:23:54.016196"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 984 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 984 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.022734"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.022734"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 985 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.026171"], ["state", "pending"], ["target_id", 985], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.026171"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1203]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 985]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 985 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 985 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.034589"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.034589"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 986 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.037661"], ["state", "pending"], ["target_id", 986], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.037661"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 986) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:54.040648"], ["target_id", 986], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 04:23:54.040648"]]  (0.4ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1204]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 986]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 986 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 986 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.051145"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.051145"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 987 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.054552"], ["state", "pending"], ["target_id", 987], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.054552"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 987) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.057433"], ["group_id", 1], ["target_id", 987], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.057433"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 987 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1205]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 987]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 987 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.066249"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.066249"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 988 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.069762"], ["state", "pending"], ["target_id", 988], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.069762"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 988 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 988 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.076173"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.076173"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 989 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.079564"], ["state", "pending"], ["target_id", 989], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.079564"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 989) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:54.082873"], ["target_id", 989], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 04:23:54.082873"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 989 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 989 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.089024"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.089024"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 990 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.094840"], ["state", "pending"], ["target_id", 990], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.094840"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 990) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.098254"], ["group_id", 1], ["target_id", 990], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.098254"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 990 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 990 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.105612"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.105612"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 991 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.108881"], ["state", "pending"], ["target_id", 991], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.108881"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 991 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'AOkJfzYT06jHYS8zpkd9XgMzZeTtkVHeA2QDV2qNmP9w' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.112035"], ["target_id", 991], ["target_type", "User"], ["token", "AOkJfzYT06jHYS8zpkd9XgMzZeTtkVHeA2QDV2qNmP9w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.112035"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.116707"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.116707"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 992 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.120072"], ["state", "pending"], ["target_id", 992], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.120072"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 992 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'uQ4_05cy0DRP-SPMgobHZAXE2yMNbQ4VHz6tCq85qhvg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.123350"], ["target_id", 992], ["target_type", "User"], ["token", "uQ4_05cy0DRP-SPMgobHZAXE2yMNbQ4VHz6tCq85qhvg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.123350"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 992 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.129127"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.129127"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 993 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.132588"], ["state", "pending"], ["target_id", 993], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.132588"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 993 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '3JylEPsXoWf_I7lgQOf6SgAAeeLCJh1vOgxHGtCQv7Gw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.135735"], ["target_id", 993], ["target_type", "User"], ["token", "3JylEPsXoWf_I7lgQOf6SgAAeeLCJh1vOgxHGtCQv7Gw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.135735"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 125 [["active", "f"], ["updated_at", "2015-09-07 04:23:54.138205"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 993 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.6ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ksnvpI0NvBEzr9SpspEiZQodP42KW0NKOFeqzErLkXwQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.141326"], ["target_id", 993], ["target_type", "User"], ["token", "ksnvpI0NvBEzr9SpspEiZQodP42KW0NKOFeqzErLkXwQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.141326"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.148686"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.148686"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 994 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 994) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:54.152505"], ["target_id", 994], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.152505"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.155936"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.155936"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 995 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 995) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:54.159778"], ["target_id", 995], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.159778"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 995 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.164886"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.164886"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 996) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:54.167767"], ["target_id", 996], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.167767"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 996 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 211]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.173802"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.173802"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 997) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:54.176521"], ["target_id", 997], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-07 04:23:54.176521"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 997 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.182006"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.182006"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 998) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.184826"], ["group_id", 1], ["target_id", 998], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.184826"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 998 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 213]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.190773"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.190773"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 999) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.194011"], ["group_id", 1], ["target_id", 999], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.194011"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.6ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 999 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.201510"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.201510"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1000) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:54.204645"], ["target_id", 1000], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.204645"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1000 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.209418"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.209418"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1001) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:54.212257"], ["target_id", 1001], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.212257"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1001 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.217909"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.217909"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1002) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:23:54.220758"], ["target_id", 1002], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.220758"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1002) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1002 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1002 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 217]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1002 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.230849"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.230849"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1003 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.235572"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.235572"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'HNLH2ckADspBiq388Zyp7AubFGaVKBPUHc9LHJ6lG4pw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.237545"], ["target_id", 1004], ["target_type", "User"], ["token", "HNLH2ckADspBiq388Zyp7AubFGaVKBPUHc9LHJ6lG4pw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.237545"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'HNLH2ckADspBiq388Zyp7AubFGaVKBPUHc9LHJ6lG4pw' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.245055"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.245055"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Sqiwi_pXccvjITKOEzfTgQOdcV2fEvJFoDoBXNUo1G5w' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.247244"], ["target_id", 1005], ["target_type", "User"], ["token", "Sqiwi_pXccvjITKOEzfTgQOdcV2fEvJFoDoBXNUo1G5w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.247244"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 128 [["active", "f"], ["updated_at", "2015-09-07 04:23:54.250844"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Sqiwi_pXccvjITKOEzfTgQOdcV2fEvJFoDoBXNUo1G5w' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.255280"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.255280"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '9pdEM3VLFKZ0LCUy-Kcetw4KvseFTYuJQLyRcsI-stCQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.257174"], ["target_id", 1006], ["target_type", "User"], ["token", "9pdEM3VLFKZ0LCUy-Kcetw4KvseFTYuJQLyRcsI-stCQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.257174"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 129 [["active", "f"], ["updated_at", "2015-09-07 04:23:54.260381"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.263429"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:23:54.263429"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'gNazO0qCnSLh_ba5ajbb1AimRy2oCXIDxTGdkZ6K9BPA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:23:54.265205"], ["target_id", 1007], ["target_type", "User"], ["token", "gNazO0qCnSLh_ba5ajbb1AimRy2oCXIDxTGdkZ6K9BPA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.265205"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.271071"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-07 04:23:54.271071"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1008 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:54.274277"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1008], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.274277"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:23:54.279543"], ["email", "2@notifyuser.com"], ["updated_at", "2015-09-07 04:23:54.279543"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1009 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:23:54.282487"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1009], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:23:54.282487"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:09.853153"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:09.853153"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.2ms) Completed 200 OK in 16ms (Views: 12.9ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:09.882997"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:09.882997"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1011 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:09.906529"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1011], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:09.906529"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1011 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1011 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 12ms  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:09.929316"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:09.929316"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1012 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:09.935112"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1012], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:09.935112"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1012 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1012 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:09.947513"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:09.947513"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1013 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:09.953145"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1013], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:09.953145"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1013 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:09.956672"], ["parent_id", 1], ["state", "pending"], ["target_id", 1013], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:09.956672"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1013 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1013 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:09.972453"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:09.972453"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1014 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:09.978468"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1014], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:09.978468"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1014 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:09.981872"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1014], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:09.981872"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1014 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:09.984968"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1014], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:09.984968"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1014 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 145ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.142062"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.142062"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1015 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.150094"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1015], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.150094"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1015 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.154226"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1015], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.154226"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1015 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.158711"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1015], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.158711"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1221"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1015 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1221') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1015]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1015 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1221 [["state", "read"], ["updated_at", "2015-09-07 04:24:10.173692"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 15ms (Views: 1.2ms | ActiveRecord: 1.8ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 1221 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.188779"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.188779"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1016 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.196004"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1016], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.196004"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1016 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.199672"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1016], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.199672"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1016 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.203389"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1016], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.203389"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1224"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1016 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1224') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1016]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1016 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1224 [["state", "read"], ["updated_at", "2015-09-07 04:24:10.212342"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.3ms | ActiveRecord: 1.6ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1224"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1016 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1224') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.2ms | ActiveRecord: 2.1ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.223476"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.223476"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1017 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.230587"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1017], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.230587"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1017 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.234900"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1017], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.234900"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1017 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.240630"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1017], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.240630"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1017 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1017 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 4ms (Views: 1.1ms | ActiveRecord: 0.9ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1017 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.255518"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.255518"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 3ms (Views: 1.9ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.272638"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.272638"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 2ms (Views: 1.4ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.287054"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.287054"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1020 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.292997"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1020], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.292997"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["1230"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1020 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1230')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1020 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1230')) Completed 500 Internal Server Error in 5ms  (0.4ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.309216"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.309216"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1021 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.315332"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1021], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.315332"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["1231"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1021 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1231')) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1021 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1231')) Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.329303"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.329303"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1022 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.342378"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1022], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.342378"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1022 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1022 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1022) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:10.363350"], ["target_id", 1022], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.363350"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1022 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 21ms (Views: 2.5ms | ActiveRecord: 1.7ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1022 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.376055"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.376055"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1023 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.382324"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1023], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.382324"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1023 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1023 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1023 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 6ms (Views: 2.1ms | ActiveRecord: 0.8ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1023 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.408731"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.408731"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1024 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.415289"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1024], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.415289"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1024 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1024) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:10.424193"], ["target_id", 1024], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.424193"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1024 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 8ms (ActiveRecord: 1.6ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.433132"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.433132"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1025 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.438856"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1025], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.438856"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1025) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:10.441874"], ["target_id", 1025], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.441874"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1025 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 220]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 4ms (ActiveRecord: 0.9ms) NotifyUser::Unsubscribe Load (0.2ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.454134"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.454134"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1026 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:10.459735"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1026], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.459735"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1026 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'iV_N-_FEKTFD1zCrro8F8Qo1R9bx6RtMAAcU8Y-VzFSA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.471738"], ["target_id", 1026], ["target_type", "User"], ["token", "iV_N-_FEKTFD1zCrro8F8Qo1R9bx6RtMAAcU8Y-VzFSA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.471738"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"iV_N-_FEKTFD1zCrro8F8Qo1R9bx6RtMAAcU8Y-VzFSA"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'iV_N-_FEKTFD1zCrro8F8Qo1R9bx6RtMAAcU8Y-VzFSA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'iV_N-_FEKTFD1zCrro8F8Qo1R9bx6RtMAAcU8Y-VzFSA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1026]]  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1026) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:10.480924"], ["target_id", 1026], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.480924"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 131 [["active", "f"], ["updated_at", "2015-09-07 04:24:10.482537"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.3ms | ActiveRecord: 2.2ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 21.7ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.0ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.4ms NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.713099"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.713099"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1027 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.716330"], ["state", "pending"], ["target_id", 1027], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.716330"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1027 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.723161"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.723161"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1028 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.726580"], ["state", "pending"], ["target_id", 1028], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.726580"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1028 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.731822"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.731822"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1029 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.734995"], ["state", "pending"], ["target_id", 1029], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.734995"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1029 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.743883"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.743883"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1030 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.746998"], ["state", "pending"], ["target_id", 1030], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.746998"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1030 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.753173"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.753173"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1031 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.756752"], ["state", "pending"], ["target_id", 1031], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.756752"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1031 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.761904"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.761904"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.765026"], ["state", "pending"], ["target_id", 1032], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.765026"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.769029"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.769029"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1033 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.772691"], ["state", "pending"], ["target_id", 1033], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.772691"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.776549"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.776549"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1034 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.779680"], ["state", "pending"], ["target_id", 1034], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.779680"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1034 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1244 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 04:24:10.782462"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.789314"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.789314"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1035 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.792921"], ["state", "pending"], ["target_id", 1035], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.792921"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1035 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1245 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 04:24:10.795786"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.801035"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.801035"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1036 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.804138"], ["state", "pending"], ["target_id", 1036], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.804138"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1036 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1246 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 04:24:10.807257"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.812427"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.812427"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1037 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.815746"], ["state", "pending"], ["target_id", 1037], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.815746"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1037 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1247 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 04:24:10.818553"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.823986"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.823986"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1038 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.827194"], ["state", "pending"], ["target_id", 1038], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.827194"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1038 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.832670"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.832670"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1039 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.836168"], ["state", "pending"], ["target_id", 1039], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.836168"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1039 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1039 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1249 [["state", "sent"], ["updated_at", "2015-09-07 04:24:10.842670"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1039 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1249 [["sent_time", "2015-09-07 04:24:10.843868"], ["updated_at", "2015-09-07 04:24:10.845199"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.849551"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.849551"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1040 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.852833"], ["state", "pending"], ["target_id", 1040], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.852833"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1040 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1040 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1250)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1040 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1250 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:10.858638"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1250]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1040]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1040 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1040]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1040 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1250 [["sent_time", "2015-09-07 04:24:10.864698"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:10.867317"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1040 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1250]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1040]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1040 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1040 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1040 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'cT_50ui5mLy26REuxsdo4AIuDW5fZz1HVTGMdCFcThzQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.878016"], ["target_id", 1040], ["target_type", "User"], ["token", "cT_50ui5mLy26REuxsdo4AIuDW5fZz1HVTGMdCFcThzQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.878016"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.2ms Sent mail to user@example.com (3.1ms) Date: Mon, 07 Sep 2015 14:24:10 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed116ad75b1_17ffb3fcf5a0601f86557f@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.888250"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.888250"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1041 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.891746"], ["state", "pending_as_aggregation_parent"], ["target_id", 1041], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.891746"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1041 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.895356"], ["state", "pending"], ["target_id", 1041], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.895356"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1041 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1041 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1252)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.902752"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.902752"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1042 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.905864"], ["state", "pending"], ["target_id", 1042], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.905864"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1042 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1042 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1253 [["state", "sent"], ["updated_at", "2015-09-07 04:24:10.909946"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1042 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1253 [["sent_time", "2015-09-07 04:24:10.911071"], ["updated_at", "2015-09-07 04:24:10.912433"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1253]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1042]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1042 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1042 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1042 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'UsfmO5rfhOcSWzGaLKDSCwdzQpw-21mCH20RhZfANmoA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.921508"], ["target_id", 1042], ["target_type", "User"], ["token", "UsfmO5rfhOcSWzGaLKDSCwdzQpw-21mCH20RhZfANmoA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.921508"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.8ms Sent mail to user@example.com (1.7ms) Date: Mon, 07 Sep 2015 14:24:10 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed116ae1eae_17ffb3fcf5a0601f865614@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.929038"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.929038"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1043 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.932609"], ["state", "pending"], ["target_id", 1043], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.932609"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1043 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1254 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-07 04:24:10.936160"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.941823"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.941823"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1044 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.945347"], ["state", "pending"], ["target_id", 1044], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.945347"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1044) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:10.948246"], ["target_id", 1044], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 04:24:10.948246"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1255]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1044]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1044 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1044 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.956302"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.956302"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1045 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.959409"], ["state", "pending"], ["target_id", 1045], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.959409"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1256]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1045]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1045 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1045 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.967156"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.967156"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1046 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.970174"], ["state", "pending"], ["target_id", 1046], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.970174"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1046 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1046 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1257 [["state", "sent"], ["updated_at", "2015-09-07 04:24:10.975568"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1046 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1257 [["sent_time", "2015-09-07 04:24:10.977028"], ["updated_at", "2015-09-07 04:24:10.978436"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1257]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1046]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1046 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1046 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1046 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'M1dFyHF0_YfzWuL6M0myBQlpglmGQ5e3rgVg5z7vcrBA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.987538"], ["target_id", 1046], ["target_type", "User"], ["token", "M1dFyHF0_YfzWuL6M0myBQlpglmGQ5e3rgVg5z7vcrBA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.987538"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 7.1ms Sent mail to user@example.com (1.6ms) Date: Mon, 07 Sep 2015 14:24:10 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed116af21ed_17ffb3fcf5a0601f86579e@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:10.995763"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:10.995763"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1047 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:10.999300"], ["state", "pending"], ["target_id", 1047], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:10.999300"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1258]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1047]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1047 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1047 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.008541"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.008541"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1048 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.011927"], ["state", "pending"], ["target_id", 1048], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.011927"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1259]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1048]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1048 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1048]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1048 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1259 [["sent_time", "2015-09-07 04:24:11.016840"], ["state", "sent"], ["updated_at", "2015-09-07 04:24:11.019176"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1048 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.025261"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.025261"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1049 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.028783"], ["state", "pending"], ["target_id", 1049], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.028783"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1049 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.032327"], ["state", "pending"], ["target_id", 1049], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.032327"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1261]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1049]] NewPostNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1049 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1049]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1049 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1261 [["sent_time", "2015-09-07 04:24:11.038818"], ["state", "sent"], ["updated_at", "2015-09-07 04:24:11.041350"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1049]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1049 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1260 [["sent_time", "2015-09-07 04:24:11.043179"], ["state", "sent"], ["updated_at", "2015-09-07 04:24:11.045998"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1049 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1049 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.054490"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.054490"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1050 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.057518"], ["state", "read"], ["target_id", 1050], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.057518"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1262]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1050]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1050 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.064901"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.064901"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1051 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1051 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.069840"], ["group_id", 2], ["state", "pending"], ["target_id", 1051], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.069840"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1263]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1051]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1051 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1051]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1051 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1051 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1263 [["sent_time", "2015-09-07 04:24:11.076414"], ["state", "sent"], ["updated_at", "2015-09-07 04:24:11.080880"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1051 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1051 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1263]] User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1051]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1051 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1051 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1051 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1051 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '-kDR6zReYcfqiFjBRP9MqA_FWOKOMaDoNo0kQDdtO8Sw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.096886"], ["target_id", 1051], ["target_type", "User"], ["token", "-kDR6zReYcfqiFjBRP9MqA_FWOKOMaDoNo0kQDdtO8Sw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.096886"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 7.5ms Sent mail to user@example.com (3.0ms) Date: Mon, 07 Sep 2015 14:24:11 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed116b18ce6_17ffb3fcf5a0601f865830@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.4ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.107927"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.107927"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1052 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1052 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.112607"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1052], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.112607"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1052 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1052 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1264 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.116711"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1052 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1052 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1264 [["sent_time", "2015-09-07 04:24:11.118039"], ["updated_at", "2015-09-07 04:24:11.120500"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1264]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.127866"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.127866"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1053 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1053 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.132203"], ["group_id", 1], ["state", "pending"], ["target_id", 1053], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.132203"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1053 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1265) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.138083"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.138083"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1054 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1054 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.142739"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1054], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.142739"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1054 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1054 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.146917"], ["group_id", 1], ["state", "pending"], ["target_id", 1054], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.146917"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1054 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1267) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.152315"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.152315"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1055 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1055 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.158674"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1055], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.158674"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1055 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1055 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.163844"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1055], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.163844"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1055 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1055 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.168444"], ["group_id", 1], ["state", "pending"], ["target_id", 1055], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.168444"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1055 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1270) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.173836"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.173836"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1056 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1056 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.178039"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 1056], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.178039"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1056 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1056 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.182548"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 1056], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.182548"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1056 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1056 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.186629"], ["group_id", 1], ["state", "pending"], ["target_id", 1056], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.186629"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1056 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1273) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.210649"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.210649"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1057 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1057 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.215242"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1057], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.215242"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1057 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1057 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.219603"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1057], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.219603"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1057 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1057 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.224248"], ["group_id", 1], ["state", "pending"], ["target_id", 1057], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.224248"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1057 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1276) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.230538"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.230538"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1058 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1058 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 18:24:11.231901"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1058], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.235445"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1058 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 04:24:11.237455') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1058 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 04:24:11.237455') ORDER BY created_at DESC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1058 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1058 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 04:24:11.244038"], ["group_id", 1], ["parent_id", 1277], ["state", "pending"], ["target_id", 1058], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.244038"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.248717"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.248717"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1059 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1059 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 03:24:11.249848"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1059], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.254980"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1059 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 04:24:11.257672')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1059 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1059 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.262230"], ["group_id", 1], ["state", "pending"], ["target_id", 1059], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.262230"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.266633"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.266633"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1060 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1060 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 03:24:11.267982"], ["group_id", 1], ["state", "pending"], ["target_id", 1060], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.271568"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1060 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 04:24:11.274033')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1060 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1060 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.278409"], ["group_id", 1], ["state", "pending"], ["target_id", 1060], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.278409"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.283167"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.283167"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1061 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1061 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.288011"], ["group_id", 1], ["state", "pending"], ["target_id", 1061], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.288011"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1061 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1283) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1061 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1283) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.296062"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.296062"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1062 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1062 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.300662"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1062], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.300662"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1062 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1062 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1284 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.307268"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1062 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1062 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1284 [["sent_time", "2015-09-07 04:24:11.308718"], ["updated_at", "2015-09-07 04:24:11.311469"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1062 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1062 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.315855"], ["group_id", 1], ["state", "pending"], ["target_id", 1062], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.315855"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1062 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1285) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1062 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1285) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.324175"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.324175"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.328507"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1063], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.328507"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1286 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.332793"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1286 [["sent_time", "2015-09-07 04:24:11.334310"], ["updated_at", "2015-09-07 04:24:11.336927"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.343156"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1063], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.343156"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1287 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.350784"]]  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1287 [["sent_time", "2015-09-07 04:24:11.352875"], ["updated_at", "2015-09-07 04:24:11.359228"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.364410"], ["group_id", 1], ["state", "pending"], ["target_id", 1063], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.364410"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1063 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1288) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1063 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1288) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.372668"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.372668"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.377325"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1064], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.377325"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1289 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.381976"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1289 [["sent_time", "2015-09-07 04:24:11.383297"], ["updated_at", "2015-09-07 04:24:11.386003"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.390940"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1064], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.390940"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1290 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.395686"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1290 [["sent_time", "2015-09-07 04:24:11.396982"], ["updated_at", "2015-09-07 04:24:11.399818"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.404785"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1064], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.404785"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1291 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.409820"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1291 [["sent_time", "2015-09-07 04:24:11.411010"], ["updated_at", "2015-09-07 04:24:11.413576"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.418499"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1064], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.418499"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1292 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.424668"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1292 [["sent_time", "2015-09-07 04:24:11.425810"], ["updated_at", "2015-09-07 04:24:11.428394"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.432845"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1064], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.432845"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1293 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.437715"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1293 [["sent_time", "2015-09-07 04:24:11.439031"], ["updated_at", "2015-09-07 04:24:11.441550"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.445990"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1064], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.445990"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1294 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.450072"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1294 [["sent_time", "2015-09-07 04:24:11.451197"], ["updated_at", "2015-09-07 04:24:11.453654"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.457962"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1064], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.457962"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1295 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.461996"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1295 [["sent_time", "2015-09-07 04:24:11.463229"], ["updated_at", "2015-09-07 04:24:11.465661"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.470328"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1064], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.470328"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1296 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.474704"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1296 [["sent_time", "2015-09-07 04:24:11.476018"], ["updated_at", "2015-09-07 04:24:11.478497"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.482653"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1064], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.482653"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1297 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.486771"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1297 [["sent_time", "2015-09-07 04:24:11.488038"], ["updated_at", "2015-09-07 04:24:11.490707"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.495445"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1064], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.495445"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1298 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.499587"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1298 [["sent_time", "2015-09-07 04:24:11.500806"], ["updated_at", "2015-09-07 04:24:11.503446"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.508303"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1064], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.508303"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1299 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.512833"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1299 [["sent_time", "2015-09-07 04:24:11.514104"], ["updated_at", "2015-09-07 04:24:11.516615"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.520938"], ["group_id", 1], ["state", "pending"], ["target_id", 1064], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.520938"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1064 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1300) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1064 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1300) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.528730"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.528730"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1065 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1065 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.532961"], ["group_id", 1], ["state", "pending"], ["target_id", 1065], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.532961"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1065 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1065 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1065 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1301)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1065 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1065 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1301 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.542859"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.547542"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.547542"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1066 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1066 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.552347"], ["group_id", 1], ["state", "pending"], ["target_id", 1066], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.552347"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1066 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1066 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1066 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1302)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1066 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1066 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1302 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.560668"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.565634"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.565634"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1067 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1067 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.571634"], ["group_id", 1], ["state", "pending"], ["target_id", 1067], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.571634"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1067 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1067 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1067 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1303)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1067 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1067 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1303 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.579979"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1303]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.586345"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.586345"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1068 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1068 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.591415"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1068], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.591415"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1068 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1068 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:26:11.591415"], ["group_id", 1], ["state", "pending"], ["target_id", 1068], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.597285"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1068 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1068 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1068 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1305)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1068 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1068 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1305 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 04:24:11.605553"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.610186"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.610186"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1069 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1069 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.614811"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1069], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.614811"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1069 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 04:24:11.617050') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1069 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 04:24:11.617050') ORDER BY created_at DESC LIMIT 1  (0.4ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1069 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1069 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 04:26:11.614811"], ["group_id", 1], ["parent_id", 1306], ["state", "pending"], ["target_id", 1069], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.623911"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1307]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.628852"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.628852"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1070 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1070 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.633365"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1070], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.633365"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1070 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1070 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.637834"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1070], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.637834"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1070 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1070 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.641985"], ["group_id", 1], ["state", "pending"], ["target_id", 1070], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.641985"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1070 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1070 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1070 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1310)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.650150"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.650150"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1071 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1071 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.654259"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1071], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.654259"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1071 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1071 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.659151"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1071], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.659151"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1071 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1071 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:11.663369"], ["group_id", 1], ["state", "pending"], ["target_id", 1071], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.663369"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1071 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1071 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1071 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1313) NewPostNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1313]]  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.674809"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.674809"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1072 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.680838"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.680838"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1073 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1073 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.687291"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.687291"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1074 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.692906"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.692906"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1075 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.695866"], ["state", "pending"], ["target_id", 1075], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.695866"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1075) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:11.698715"], ["target_id", 1075], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.698715"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1075 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.703687"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.703687"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1076 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.706821"], ["state", "pending"], ["target_id", 1076], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.706821"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1076 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.712133"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.712133"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1077 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.716070"], ["state", "pending"], ["target_id", 1077], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.716070"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1077) LIMIT 1 SQL (0.5ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:11.719302"], ["target_id", 1077], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 04:24:11.719302"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1077 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1077 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.726886"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.726886"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1078 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.729987"], ["state", "pending"], ["target_id", 1078], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.729987"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1078 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1078 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.735944"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.735944"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1079 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.739244"], ["state", "pending"], ["target_id", 1079], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.739244"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1079) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.742138"], ["group_id", 1], ["target_id", 1079], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.742138"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1079 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1079 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.749317"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.749317"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1080 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.752429"], ["state", "pending"], ["target_id", 1080], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.752429"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1080) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:11.755363"], ["target_id", 1080], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.755363"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1080 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1080 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.762128"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.762128"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1081 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.765158"], ["state", "pending"], ["target_id", 1081], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.765158"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1081 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1081 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1320 [["group_id", 1], ["updated_at", "2015-09-07 04:24:11.768932"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1081 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1081 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.777125"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.777125"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1082 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.780131"], ["state", "pending"], ["target_id", 1082], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.780131"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1321]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1082]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1082 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1082 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.787662"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.787662"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1083 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.790740"], ["state", "pending"], ["target_id", 1083], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.790740"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1083) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:11.793679"], ["target_id", 1083], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 04:24:11.793679"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1322]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1083]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1083 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1083 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.800884"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.800884"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1084 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.803811"], ["state", "pending"], ["target_id", 1084], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.803811"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1084) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.806902"], ["group_id", 1], ["target_id", 1084], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.806902"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1084 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1323]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1084]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1084 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.815651"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.815651"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1085 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.818741"], ["state", "pending"], ["target_id", 1085], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.818741"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1085 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1085 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.827073"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.827073"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1086 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.830057"], ["state", "pending"], ["target_id", 1086], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.830057"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1086) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:11.832836"], ["target_id", 1086], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 04:24:11.832836"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1086 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1086 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.838677"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.838677"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1087 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.841864"], ["state", "pending"], ["target_id", 1087], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.841864"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1087) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.844646"], ["group_id", 1], ["target_id", 1087], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.844646"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1087 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1087 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.851442"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.851442"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1088 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.854650"], ["state", "pending"], ["target_id", 1088], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.854650"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1088 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'NH3dgcjZLvlJpn5wd4C4bAV4QgTDKR3-AIG9x2tGBzYA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.858240"], ["target_id", 1088], ["target_type", "User"], ["token", "NH3dgcjZLvlJpn5wd4C4bAV4QgTDKR3-AIG9x2tGBzYA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.858240"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.862449"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.862449"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1089 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.865415"], ["state", "pending"], ["target_id", 1089], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.865415"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1089 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'znHSOTSUGnbW0r2Q5t5XxgkN2p0PQi9ApG3AXvWTEsfQ' LIMIT 1 SQL (0.7ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.868425"], ["target_id", 1089], ["target_type", "User"], ["token", "znHSOTSUGnbW0r2Q5t5XxgkN2p0PQi9ApG3AXvWTEsfQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.868425"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1089 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.877187"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.877187"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1090 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.880840"], ["state", "pending"], ["target_id", 1090], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.880840"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1090 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'WdDH1PR0xGBX7_TlrtnzZQWD15kI99fD1S5cKkaIWDHg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.885235"], ["target_id", 1090], ["target_type", "User"], ["token", "WdDH1PR0xGBX7_TlrtnzZQWD15kI99fD1S5cKkaIWDHg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.885235"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 138 [["active", "f"], ["updated_at", "2015-09-07 04:24:11.888359"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1090 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ALG3w-FtTET_fqRRw_Xz7gOjW0LDMZ5HuxrvvZCPytMg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.892229"], ["target_id", 1090], ["target_type", "User"], ["token", "ALG3w-FtTET_fqRRw_Xz7gOjW0LDMZ5HuxrvvZCPytMg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.892229"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.899797"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.899797"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1091 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.9ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1091) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:11.905609"], ["target_id", 1091], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.905609"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.910646"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.910646"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1092 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (1.0ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1092) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:11.916707"], ["target_id", 1092], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.916707"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (1.2ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1092 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.924750"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.924750"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1093) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:11.927749"], ["target_id", 1093], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.927749"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1093 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 233]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.936605"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.936605"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1094) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:11.939900"], ["target_id", 1094], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-07 04:24:11.939900"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1094 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.946425"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.946425"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.6ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1095) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.950338"], ["group_id", 1], ["target_id", 1095], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.950338"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 235]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.956848"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.956848"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1096) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:11.959566"], ["group_id", 1], ["target_id", 1096], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.959566"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1096 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.964660"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.964660"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1097) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:11.967397"], ["target_id", 1097], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.967397"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1097 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.973928"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.973928"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1098) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:11.976575"], ["target_id", 1098], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.976575"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1098 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.981676"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.981676"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1099) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 04:24:11.984642"], ["target_id", 1099], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:11.984642"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1099) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1099 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1099 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 239]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1099 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.994333"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.994333"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1100 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:11.998612"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:11.998612"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'CYHGedRrj6Q4Nat1m658WAMB7gnPFCBgb5iIReU_50HA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:12.000316"], ["target_id", 1101], ["target_type", "User"], ["token", "CYHGedRrj6Q4Nat1m658WAMB7gnPFCBgb5iIReU_50HA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:12.000316"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'CYHGedRrj6Q4Nat1m658WAMB7gnPFCBgb5iIReU_50HA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:12.005374"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:12.005374"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'UW0V5vlAg82uMolF6A7O-AQhoxexTc-FqZtZnHnwt3xQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:12.007218"], ["target_id", 1102], ["target_type", "User"], ["token", "UW0V5vlAg82uMolF6A7O-AQhoxexTc-FqZtZnHnwt3xQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:12.007218"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 141 [["active", "f"], ["updated_at", "2015-09-07 04:24:12.010413"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'UW0V5vlAg82uMolF6A7O-AQhoxexTc-FqZtZnHnwt3xQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:12.014206"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:12.014206"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'cwBSuZkdCotDl79bSf6vNQgMJHYacBy3pvseTTSRe2xg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:12.015940"], ["target_id", 1103], ["target_type", "User"], ["token", "cwBSuZkdCotDl79bSf6vNQgMJHYacBy3pvseTTSRe2xg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:12.015940"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.5ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 142 [["active", "f"], ["updated_at", "2015-09-07 04:24:12.018765"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:12.023304"], ["email", "user@example.com"], ["updated_at", "2015-09-07 04:24:12.023304"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'A03d1o3pDJ9bbe5D02p5NQ_bEq_Aq7V8nDYZujeMKFqQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 04:24:12.025077"], ["target_id", 1104], ["target_type", "User"], ["token", "A03d1o3pDJ9bbe5D02p5NQ_bEq_Aq7V8nDYZujeMKFqQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:12.025077"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:12.030697"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-07 04:24:12.030697"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1105 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:12.033506"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1105], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:12.033506"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 04:24:12.038201"], ["email", "2@notifyuser.com"], ["updated_at", "2015-09-07 04:24:12.038201"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1106 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:24:12.041017"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1106], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 04:24:12.041017"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (24.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:35:37.499850"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:35:37.499850"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (22.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1107 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (4.0ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:35:37.592266"], ["state", "pending"], ["target_id", 1107], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:35:37.592266"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:35:37.648071"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:35:37.648071"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1108 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:35:37.652169"], ["state", "pending"], ["target_id", 1108], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:35:37.652169"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:37:32.825989"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:37:32.825989"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1109 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:37:32.853625"], ["state", "pending"], ["target_id", 1109], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:37:32.853625"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:37:32.865703"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:37:32.865703"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1110 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:37:32.869163"], ["state", "pending"], ["target_id", 1110], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:37:32.869163"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1110 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:38:46.170367"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:38:46.170367"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1111 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:38:46.210144"], ["state", "pending"], ["target_id", 1111], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:38:46.210144"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:38:46.225734"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:38:46.225734"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1112 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:38:46.229456"], ["state", "pending"], ["target_id", 1112], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:38:46.229456"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1112 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:39:28.820276"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:39:28.820276"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1113 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:39:28.849351"], ["state", "pending"], ["target_id", 1113], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:39:28.849351"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:39:28.924783"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:39:28.924783"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1114 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:39:28.928062"], ["state", "pending"], ["target_id", 1114], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:39:28.928062"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1114 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:40:02.679456"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:40:02.679456"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1115 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:40:02.711702"], ["state", "pending"], ["target_id", 1115], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:40:02.711702"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:40:02.726510"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:40:02.726510"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1116 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:40:02.730428"], ["state", "pending"], ["target_id", 1116], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:40:02.730428"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1116 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:40:59.871490"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:40:59.871490"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1117 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:40:59.899185"], ["state", "pending"], ["target_id", 1117], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:40:59.899185"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:40:59.910424"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:40:59.910424"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1118 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:40:59.913930"], ["state", "pending"], ["target_id", 1118], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:40:59.913930"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1118 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:41:14.409734"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:41:14.409734"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1119 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:41:14.438309"], ["state", "pending"], ["target_id", 1119], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:41:14.438309"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1119 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:41:14.453094"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:41:14.453094"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1120 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:41:14.456421"], ["state", "pending"], ["target_id", 1120], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:41:14.456421"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1120 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:43:41.486567"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:43:41.486567"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1121 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:43:41.515632"], ["state", "pending"], ["target_id", 1121], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:43:41.515632"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1121 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:43:41.529357"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:43:41.529357"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1122 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:43:41.532506"], ["state", "pending"], ["target_id", 1122], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:43:41.532506"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1122 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:43:59.921782"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:43:59.921782"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1123 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:43:59.949145"], ["state", "pending"], ["target_id", 1123], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:43:59.949145"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1123 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:43:59.963678"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:43:59.963678"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1124 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:43:59.967717"], ["state", "pending"], ["target_id", 1124], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:43:59.967717"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (2.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1124 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (1.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:45:13.793273"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:45:13.793273"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1125 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:45:13.820830"], ["state", "pending"], ["target_id", 1125], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:45:13.820830"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1125 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1125 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:45:13.867084"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:45:13.867084"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1126 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:45:13.870725"], ["state", "pending"], ["target_id", 1126], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:45:13.870725"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1126 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:45:42.134831"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:45:42.134831"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1127 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:45:42.170933"], ["state", "pending"], ["target_id", 1127], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:45:42.170933"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1127 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:45:42.187579"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:45:42.187579"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1128 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:45:42.191362"], ["state", "pending"], ["target_id", 1128], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:45:42.191362"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1128 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:45:52.709401"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:45:52.709401"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1129 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:45:52.740155"], ["state", "pending"], ["target_id", 1129], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:45:52.740155"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1129 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1129 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:45:52.787252"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:45:52.787252"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1130 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:45:52.790739"], ["state", "pending"], ["target_id", 1130], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:45:52.790739"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1130 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:45:59.589340"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:45:59.589340"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1131 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:45:59.616181"], ["state", "pending"], ["target_id", 1131], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:45:59.616181"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1131 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1131 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:45:59.660686"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:45:59.660686"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1132 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:45:59.664198"], ["state", "pending"], ["target_id", 1132], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:45:59.664198"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1132 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:46:45.740627"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:46:45.740627"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1133 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.8ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:46:45.775544"], ["state", "pending"], ["target_id", 1133], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:46:45.775544"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1133 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1133 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:46:45.828253"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:46:45.828253"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1134 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:46:45.832208"], ["state", "pending"], ["target_id", 1134], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:46:45.832208"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1134 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1134 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:47:16.219843"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:47:16.219843"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1135 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:47:16.247580"], ["state", "pending"], ["target_id", 1135], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:47:16.247580"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1135 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending')) Notification target, User, does not respond to the method, .  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:47:16.293960"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:47:16.293960"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1136 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:47:16.297661"], ["state", "pending"], ["target_id", 1136], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:47:16.297661"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1136 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending')) Notification target, User, does not respond to the method, .  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:47:28.432927"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:47:28.432927"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1137 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:47:28.461421"], ["state", "pending"], ["target_id", 1137], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:47:28.461421"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1137 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1137 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:47:28.510504"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:47:28.510504"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1138 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:47:28.513956"], ["state", "pending"], ["target_id", 1138], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:47:28.513956"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1138 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1138 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:48:29.377940"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:48:29.377940"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1139 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:48:29.405128"], ["state", "pending"], ["target_id", 1139], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:48:29.405128"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1139 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending')) Notification target, User, does not respond to the method, .  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:48:29.447319"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:48:29.447319"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1140 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:48:29.450788"], ["state", "pending"], ["target_id", 1140], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:48:29.450788"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1140 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending')) Notification target, User, does not respond to the method, .  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:48:53.422861"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:48:53.422861"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1141 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:48:53.450878"], ["state", "pending"], ["target_id", 1141], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:48:53.450878"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1141 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending')) Notification target, User, does not respond to the method, .  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:48:53.495068"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:48:53.495068"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1142 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:48:53.498758"], ["state", "pending"], ["target_id", 1142], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:48:53.498758"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1142 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending')) Notification target, User, does not respond to the method, .  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:09.108324"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:09.108324"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1143 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:09.136451"], ["state", "pending"], ["target_id", 1143], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:09.136451"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1143 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending')) Notification target, User, does not respond to the method, .  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:09.189778"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:09.189778"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1144 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:09.193853"], ["state", "pending"], ["target_id", 1144], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:09.193853"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1144 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending')) Notification target, User, does not respond to the method, .  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:23.504725"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:23.504725"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1145 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:23.532833"], ["state", "pending"], ["target_id", 1145], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:23.532833"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1145 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1145 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:23.578025"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:23.578025"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1146 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:23.581581"], ["state", "pending"], ["target_id", 1146], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:23.581581"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1146 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1146 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:45.925755"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:45.925755"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.2ms) Completed 200 OK in 18ms (Views: 13.5ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:45.958745"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:45.958745"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1148 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (5.9ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:45.982820"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1148], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:45.982820"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1148 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (6.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1148 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 18ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.016185"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.016185"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.021792"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1149], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.021792"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1149 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1149 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.034209"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.034209"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.040032"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.040032"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.043538"], ["parent_id", 1], ["state", "pending"], ["target_id", 1150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.043538"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1150 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1150 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.059784"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.059784"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1151 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.065221"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1151], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.065221"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1151 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.068905"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1151], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.068905"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1151 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.072108"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1151], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.072108"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1151 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 152ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.235579"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.235579"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.242751"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1152], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.242751"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.246462"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1152], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.246462"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.250741"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1152], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.250741"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1379"} NotifyUser::BaseNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1152 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1379') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.7ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1152]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1379 [["state", "read"], ["updated_at", "2015-09-07 10:49:46.273097"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 17ms (Views: 1.8ms | ActiveRecord: 2.4ms) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 1379 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.297006"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.297006"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.304029"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1153], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.304029"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.307891"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1153], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.307891"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.311574"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1153], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.311574"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1382"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1153 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1382') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1153]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1382 [["state", "read"], ["updated_at", "2015-09-07 10:49:46.320847"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.3ms | ActiveRecord: 1.6ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1382"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1153 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1382') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.2ms | ActiveRecord: 1.9ms)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.331109"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.331109"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1154 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.337457"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1154], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.337457"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1154 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.342884"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1154], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.342884"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1154 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.346294"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1154], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.346294"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1154 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1154 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 4ms (Views: 1.0ms | ActiveRecord: 0.9ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1154 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.359379"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.359379"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 3ms (Views: 2.2ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.376331"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.376331"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 3ms (Views: 2.0ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.392804"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.392804"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1157 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.400088"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1157], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.400088"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["1388"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1157 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1388')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1157 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1388')) Completed 500 Internal Server Error in 7ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.417647"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.417647"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1158 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.426149"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1158], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.426149"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["1389"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1158 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1389')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1158 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1389')) Completed 500 Internal Server Error in 6ms  (0.5ms) ROLLBACK  (0.5ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.445014"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.445014"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.452745"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1159], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.452745"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1159) LIMIT 1 SQL (18.5ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:46.475271"], ["target_id", 1159], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.475271"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 41ms (Views: 2.5ms | ActiveRecord: 20.2ms) NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.507590"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.507590"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.513873"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1160], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.513873"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 7ms (Views: 3.2ms | ActiveRecord: 0.7ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.541977"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.541977"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1161 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.548698"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1161], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.548698"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1161 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1161) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:46.555814"], ["target_id", 1161], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.555814"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1161 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 7ms (ActiveRecord: 1.4ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.565690"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.565690"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1162 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.572033"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1162], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.572033"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1162) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:46.575319"], ["target_id", 1162], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.575319"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1162 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 242]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 5ms (ActiveRecord: 1.0ms) NotifyUser::Unsubscribe Load (0.2ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.589203"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.589203"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1163 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:46.596581"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1163], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.596581"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.9ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1163 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.5ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'tXgMPoETuWDU--e7o25sAw-0NgeO1Dchb7TXNIKjUSNg' LIMIT 1 SQL (1.6ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:46.606776"], ["target_id", 1163], ["target_type", "User"], ["token", "tXgMPoETuWDU--e7o25sAw-0NgeO1Dchb7TXNIKjUSNg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.606776"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"tXgMPoETuWDU--e7o25sAw-0NgeO1Dchb7TXNIKjUSNg"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'tXgMPoETuWDU--e7o25sAw-0NgeO1Dchb7TXNIKjUSNg' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'tXgMPoETuWDU--e7o25sAw-0NgeO1Dchb7TXNIKjUSNg' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1163]]  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1163) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:46.618238"], ["target_id", 1163], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.618238"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 144 [["active", "f"], ["updated_at", "2015-09-07 10:49:46.619968"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.3ms | ActiveRecord: 2.4ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.626153"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.626153"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1164 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:46.629684"], ["state", "pending"], ["target_id", 1164], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.629684"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1164 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1164 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.640439"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.640439"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1165 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:46.643592"], ["state", "pending"], ["target_id", 1165], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.643592"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1165 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1165 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.3ms) SAVEPOINT active_record_1  (5.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 28.2ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.1ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.6ms NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.921881"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.921881"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1166 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:46.925438"], ["state", "pending"], ["target_id", 1166], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.925438"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1166 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.931702"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.931702"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1167 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:46.935035"], ["state", "pending"], ["target_id", 1167], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.935035"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1167 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.940863"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.940863"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1168 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:46.943976"], ["state", "pending"], ["target_id", 1168], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.943976"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1168 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.953668"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.953668"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1169 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:46.957019"], ["state", "pending"], ["target_id", 1169], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.957019"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1169 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.963483"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.963483"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1170 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:46.966895"], ["state", "pending"], ["target_id", 1170], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.966895"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1170 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.972094"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.972094"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1171 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:46.975428"], ["state", "pending"], ["target_id", 1171], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.975428"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.979310"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.979310"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1172 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:46.982636"], ["state", "pending"], ["target_id", 1172], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.982636"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.986972"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.986972"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1173 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:46.990147"], ["state", "pending"], ["target_id", 1173], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:46.990147"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1173 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1404 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 10:49:46.993049"]]  (0.4ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:46.999986"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:46.999986"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1174 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.003254"], ["state", "pending"], ["target_id", 1174], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.003254"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1174 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1405 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 10:49:47.006167"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.011422"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.011422"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1175 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.014912"], ["state", "pending"], ["target_id", 1175], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.014912"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1175 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1406 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 10:49:47.017690"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.022940"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.022940"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1176 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.026303"], ["state", "pending"], ["target_id", 1176], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.026303"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1176 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1407 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-07 10:49:47.029165"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.034419"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.034419"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1177 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.037698"], ["state", "pending"], ["target_id", 1177], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.037698"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1177 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.043555"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.043555"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1178 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.048357"], ["state", "pending"], ["target_id", 1178], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.048357"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1178 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1178 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1409 [["state", "sent"], ["updated_at", "2015-09-07 10:49:47.053612"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1178 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1409 [["sent_time", "2015-09-07 10:49:47.054814"], ["updated_at", "2015-09-07 10:49:47.056193"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.060579"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.060579"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1179 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.063806"], ["state", "pending"], ["target_id", 1179], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.063806"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1179 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1179 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1410)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1179 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1410 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.069639"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1410]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1179]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1179 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1179]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1179 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1410 [["sent_time", "2015-09-07 10:49:47.077864"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.080469"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1179 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1410]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1179]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1179 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1179 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1179 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'QupdOANmMrzOMySu5SHNQwuXJjXKODtNfEvVB_sbbWEg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.090778"], ["target_id", 1179], ["target_type", "User"], ["token", "QupdOANmMrzOMySu5SHNQwuXJjXKODtNfEvVB_sbbWEg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.090778"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.2ms Sent mail to user@example.com (6.2ms) Date: Mon, 07 Sep 2015 20:49:47 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed6bcb17c6d_61163fe6bdc6020860528@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.102502"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.102502"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1180 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.105665"], ["state", "pending_as_aggregation_parent"], ["target_id", 1180], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.105665"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1180 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.109170"], ["state", "pending"], ["target_id", 1180], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.109170"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1180 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1180 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1412)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.116288"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.116288"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1181 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.119545"], ["state", "pending"], ["target_id", 1181], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.119545"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1181 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1181 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1413 [["state", "sent"], ["updated_at", "2015-09-07 10:49:47.123850"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1181 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1413 [["sent_time", "2015-09-07 10:49:47.124987"], ["updated_at", "2015-09-07 10:49:47.126359"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1413]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1181]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1181 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1181 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1181 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'YceKZIm_4etEAvz1vTt8vA6n8Kp5dBGI06PYmIkKCGCg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.136954"], ["target_id", 1181], ["target_type", "User"], ["token", "YceKZIm_4etEAvz1vTt8vA6n8Kp5dBGI06PYmIkKCGCg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.136954"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.6ms Sent mail to user@example.com (1.8ms) Date: Mon, 07 Sep 2015 20:49:47 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed6bcb22701_61163fe6bdc60208606da@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.145541"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.145541"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1182 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.150786"], ["state", "pending"], ["target_id", 1182], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.150786"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1182 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1414 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-07 10:49:47.153890"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.157979"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.157979"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1183 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.161426"], ["state", "pending"], ["target_id", 1183], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.161426"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (1.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1183) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:47.168337"], ["target_id", 1183], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 10:49:47.168337"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1415]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1183]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1183 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1183 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.180684"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.180684"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1184 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.184058"], ["state", "pending"], ["target_id", 1184], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.184058"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1416]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1184]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1184 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1184 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.192521"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.192521"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1185 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.197455"], ["state", "pending"], ["target_id", 1185], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.197455"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1185 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1185 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1417 [["state", "sent"], ["updated_at", "2015-09-07 10:49:47.202538"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1185 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1417 [["sent_time", "2015-09-07 10:49:47.203733"], ["updated_at", "2015-09-07 10:49:47.205219"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1417]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1185]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1185 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1185 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1185 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'cib9QTsD3Kw_Yg8rT1hXAAPYM1RDy7eM4s3m-6rk3Rng' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.214182"], ["target_id", 1185], ["target_type", "User"], ["token", "cib9QTsD3Kw_Yg8rT1hXAAPYM1RDy7eM4s3m-6rk3Rng"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.214182"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.7ms Sent mail to user@example.com (1.8ms) Date: Mon, 07 Sep 2015 20:49:47 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed6bcb352cb_61163fe6bdc60208607d6@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.221808"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.221808"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1186 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.225240"], ["state", "pending"], ["target_id", 1186], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.225240"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1418]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1186]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1186 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1186 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.233876"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.233876"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1187 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.237221"], ["state", "pending"], ["target_id", 1187], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.237221"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1419]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1187]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1187 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1187]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1187 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1419 [["sent_time", "2015-09-07 10:49:47.241938"], ["state", "sent"], ["updated_at", "2015-09-07 10:49:47.244534"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1187 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.252502"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.252502"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1188 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.255733"], ["state", "pending"], ["target_id", 1188], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.255733"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1188 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.259219"], ["state", "pending"], ["target_id", 1188], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.259219"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1421]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1188]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1188 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1188]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1188 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1421 [["sent_time", "2015-09-07 10:49:47.263544"], ["state", "sent"], ["updated_at", "2015-09-07 10:49:47.265874"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1188]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1188 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1420 [["sent_time", "2015-09-07 10:49:47.267566"], ["state", "sent"], ["updated_at", "2015-09-07 10:49:47.270219"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1188 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1188 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.277953"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.277953"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1189 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.281486"], ["state", "read"], ["target_id", 1189], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.281486"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1422]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1189]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1189 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.289333"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.289333"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1190 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1190 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.293870"], ["group_id", 2], ["state", "pending"], ["target_id", 1190], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.293870"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1423]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1190]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1190 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1190]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1190 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1190 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1423 [["sent_time", "2015-09-07 10:49:47.300918"], ["state", "sent"], ["updated_at", "2015-09-07 10:49:47.304467"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1190 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1190 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1423]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1190]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1190 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1190 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1190 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1190 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'xrxrWPasb7DeVT5SohpqTQMAd3nGNwLrHn5XZ8d5iNhA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.316843"], ["target_id", 1190], ["target_type", "User"], ["token", "xrxrWPasb7DeVT5SohpqTQMAd3nGNwLrHn5XZ8d5iNhA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.316843"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.5ms Sent mail to user@example.com (1.7ms) Date: Mon, 07 Sep 2015 20:49:47 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ed6bcb4e2f5_61163fe6bdc60208608e0@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.324545"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.324545"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1191 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1191 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.329033"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1191], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.329033"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1191 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1191 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1424 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.333504"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1191 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1191 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1424 [["sent_time", "2015-09-07 10:49:47.334795"], ["updated_at", "2015-09-07 10:49:47.337194"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1424]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.343961"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.343961"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1192 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1192 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.349947"], ["group_id", 1], ["state", "pending"], ["target_id", 1192], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.349947"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1192 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1425) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.355537"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.355537"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1193 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1193 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.359968"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1193], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.359968"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1193 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1193 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.364666"], ["group_id", 1], ["state", "pending"], ["target_id", 1193], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.364666"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1193 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1427) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.370360"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.370360"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1194 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1194 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.374809"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1194], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.374809"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1194 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1194 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.379125"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1194], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.379125"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1194 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1194 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.383685"], ["group_id", 1], ["state", "pending"], ["target_id", 1194], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.383685"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1194 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1430) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.390171"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.390171"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1195 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1195 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.398031"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 1195], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.398031"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1195 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1195 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.415720"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 1195], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.415720"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1195 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1195 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.422763"], ["group_id", 1], ["state", "pending"], ["target_id", 1195], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.422763"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1195 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1433) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.432959"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.432959"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1196 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1196 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.440052"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1196], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.440052"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1196 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1196 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.447774"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1196], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.447774"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1196 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1196 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.456033"], ["group_id", 1], ["state", "pending"], ["target_id", 1196], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.456033"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1196 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1436) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.466401"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.466401"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1197 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1197 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 00:49:47.468108"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1197], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.474543"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1197 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 10:49:47.477631') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1197 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 10:49:47.477631') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1197 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1197 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 10:49:47.484392"], ["group_id", 1], ["parent_id", 1437], ["state", "pending"], ["target_id", 1197], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.484392"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.489289"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.489289"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1198 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1198 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 09:49:47.490573"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1198], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.494238"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1198 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 10:49:47.496492')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1198 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1198 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.501182"], ["group_id", 1], ["state", "pending"], ["target_id", 1198], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.501182"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.505435"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.505435"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1199 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1199 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-06 09:49:47.506625"], ["group_id", 1], ["state", "pending"], ["target_id", 1199], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.510339"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1199 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 10:49:47.514366')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1199 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1199 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.519442"], ["group_id", 1], ["state", "pending"], ["target_id", 1199], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.519442"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.524169"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.524169"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1200 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1200 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.528618"], ["group_id", 1], ["state", "pending"], ["target_id", 1200], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.528618"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1200 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1443) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1200 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1443) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.536391"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.536391"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1201 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1201 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.541810"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1201], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.541810"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1201 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1201 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1444 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.546049"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1201 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1201 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1444 [["sent_time", "2015-09-07 10:49:47.547318"], ["updated_at", "2015-09-07 10:49:47.550283"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1201 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1201 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.554887"], ["group_id", 1], ["state", "pending"], ["target_id", 1201], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.554887"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1201 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1445) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1201 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1445) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.6ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.566449"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.566449"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.572126"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1202], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.572126"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1446 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.576594"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1446 [["sent_time", "2015-09-07 10:49:47.577817"], ["updated_at", "2015-09-07 10:49:47.580656"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.585293"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1202], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.585293"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1447 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.590193"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1447 [["sent_time", "2015-09-07 10:49:47.591568"], ["updated_at", "2015-09-07 10:49:47.594465"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.599214"], ["group_id", 1], ["state", "pending"], ["target_id", 1202], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.599214"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1202 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1448) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1202 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1448) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.607872"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.607872"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.614395"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1203], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.614395"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1449 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.619307"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1449 [["sent_time", "2015-09-07 10:49:47.620660"], ["updated_at", "2015-09-07 10:49:47.623508"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.628276"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1203], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.628276"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1450 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.632566"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1450 [["sent_time", "2015-09-07 10:49:47.633845"], ["updated_at", "2015-09-07 10:49:47.636815"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.643017"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1203], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.643017"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1451 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.647257"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1451 [["sent_time", "2015-09-07 10:49:47.648633"], ["updated_at", "2015-09-07 10:49:47.651239"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.656178"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1203], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.656178"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1452 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.660430"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1452 [["sent_time", "2015-09-07 10:49:47.661729"], ["updated_at", "2015-09-07 10:49:47.666026"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.670966"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1203], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.670966"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1453 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.675277"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1453 [["sent_time", "2015-09-07 10:49:47.676550"], ["updated_at", "2015-09-07 10:49:47.679202"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.683635"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1203], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.683635"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1454 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.687775"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1454 [["sent_time", "2015-09-07 10:49:47.688960"], ["updated_at", "2015-09-07 10:49:47.691612"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.696489"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1203], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.696489"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1455 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.700640"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1455 [["sent_time", "2015-09-07 10:49:47.701830"], ["updated_at", "2015-09-07 10:49:47.704377"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.708944"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1203], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.708944"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1456 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.712954"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1456 [["sent_time", "2015-09-07 10:49:47.714180"], ["updated_at", "2015-09-07 10:49:47.716720"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.721793"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1203], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.721793"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1457 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.726100"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1457 [["sent_time", "2015-09-07 10:49:47.727251"], ["updated_at", "2015-09-07 10:49:47.729812"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.734302"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1203], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.734302"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1458 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.738428"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1458 [["sent_time", "2015-09-07 10:49:47.739527"], ["updated_at", "2015-09-07 10:49:47.741941"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.746472"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1203], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.746472"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1459 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.750788"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1459 [["sent_time", "2015-09-07 10:49:47.751953"], ["updated_at", "2015-09-07 10:49:47.754500"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.759157"], ["group_id", 1], ["state", "pending"], ["target_id", 1203], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.759157"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1203 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1460) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1203 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1460) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.767682"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.767682"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1204 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1204 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.772299"], ["group_id", 1], ["state", "pending"], ["target_id", 1204], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.772299"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1204 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1204 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1204 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1461)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1204 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1204 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1461 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.783530"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.788407"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.788407"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1205 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1205 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.792882"], ["group_id", 1], ["state", "pending"], ["target_id", 1205], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.792882"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1205 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1205 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1205 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1462)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1205 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1205 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1462 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.801708"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.806405"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.806405"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1206 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1206 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.810785"], ["group_id", 1], ["state", "pending"], ["target_id", 1206], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.810785"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1206 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1206 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1206 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1463)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1206 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1206 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1463 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.820986"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1463]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.826945"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.826945"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1207 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1207 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.831754"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1207], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.831754"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1207 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1207 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:51:47.831754"], ["group_id", 1], ["state", "pending"], ["target_id", 1207], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.836468"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1207 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1207 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1207 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1465)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1207 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1207 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1465 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-07 10:49:47.844739"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.849593"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.849593"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1208 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1208 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.854052"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1208], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.854052"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1208 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 10:49:47.856035') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1208 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-06 10:49:47.856035') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1208 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1208 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-07 10:51:47.854052"], ["group_id", 1], ["parent_id", 1466], ["state", "pending"], ["target_id", 1208], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.861119"]]  (0.4ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1467]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.868244"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.868244"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1209 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1209 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.872605"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1209], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.872605"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1209 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1209 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.876722"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1209], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.876722"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1209 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1209 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.880842"], ["group_id", 1], ["state", "pending"], ["target_id", 1209], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.880842"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1209 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1209 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1209 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1470)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.888632"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.888632"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.893429"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1210], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.893429"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.898298"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1210], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.898298"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:47.902765"], ["group_id", 1], ["state", "pending"], ["target_id", 1210], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.902765"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1210 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1473) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1473]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.912031"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.912031"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1211 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.919378"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.919378"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1212 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1212 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.926149"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.926149"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1213 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.932154"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.932154"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1214 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.935386"], ["state", "pending"], ["target_id", 1214], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.935386"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1214) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:47.938474"], ["target_id", 1214], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.938474"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1214 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.943291"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.943291"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1215 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.946764"], ["state", "pending"], ["target_id", 1215], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.946764"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1215 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.952062"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.952062"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1216 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.955320"], ["state", "pending"], ["target_id", 1216], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.955320"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1216) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:47.958055"], ["target_id", 1216], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 10:49:47.958055"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1216 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1216 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.965131"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.965131"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1217 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.968515"], ["state", "pending"], ["target_id", 1217], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.968515"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1217 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1217 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.974585"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.974585"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1218 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.977720"], ["state", "pending"], ["target_id", 1218], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.977720"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1218) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.980754"], ["group_id", 1], ["target_id", 1218], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.980754"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1218 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1218 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:47.987665"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:47.987665"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1219 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:47.990835"], ["state", "pending"], ["target_id", 1219], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.990835"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1219) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:47.993674"], ["target_id", 1219], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:47.993674"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1219 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1219 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.000753"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.000753"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1220 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.004385"], ["state", "pending"], ["target_id", 1220], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.004385"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1220 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1220 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1480 [["group_id", 1], ["updated_at", "2015-09-07 10:49:48.008543"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1220 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1220 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.017959"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.017959"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.021360"], ["state", "pending"], ["target_id", 1221], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.021360"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1481]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1221]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.029762"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.029762"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.033548"], ["state", "pending"], ["target_id", 1222], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.033548"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1222) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:48.036732"], ["target_id", 1222], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 10:49:48.036732"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1482]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1222]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.044618"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.044618"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.048132"], ["state", "pending"], ["target_id", 1223], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.048132"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1223) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.051454"], ["group_id", 1], ["target_id", 1223], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.051454"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1483]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1223]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.060760"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.060760"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1224 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.065588"], ["state", "pending"], ["target_id", 1224], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.065588"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1224 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1224 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.072186"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.072186"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1225 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.075515"], ["state", "pending"], ["target_id", 1225], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.075515"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1225) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:48.078268"], ["target_id", 1225], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-07 10:49:48.078268"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1225 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1225 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.084095"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.084095"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1226 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.087205"], ["state", "pending"], ["target_id", 1226], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.087205"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1226) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.090103"], ["group_id", 1], ["target_id", 1226], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.090103"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1226 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1226 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.097250"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.097250"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1227 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.100883"], ["state", "pending"], ["target_id", 1227], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.100883"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1227 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'An9oHOEWhNKyDwHBX11dfgBFU0paHsvm4PnmQYbzZyIw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.104186"], ["target_id", 1227], ["target_type", "User"], ["token", "An9oHOEWhNKyDwHBX11dfgBFU0paHsvm4PnmQYbzZyIw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.104186"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.108582"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.108582"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1228 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.9ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.111872"], ["state", "pending"], ["target_id", 1228], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.111872"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1228 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'jLeoMMJZpdAgMW9yfMmQDQYyFLoyxVZeTKnO686Wj4Zw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.117103"], ["target_id", 1228], ["target_type", "User"], ["token", "jLeoMMJZpdAgMW9yfMmQDQYyFLoyxVZeTKnO686Wj4Zw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.117103"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1228 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.123111"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.123111"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1229 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.126465"], ["state", "pending"], ["target_id", 1229], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.126465"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1229 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'qKbQFcu-Jnm5w6JKYeeyBQdDct6oxfgociUyhsjKF59Q' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.130422"], ["target_id", 1229], ["target_type", "User"], ["token", "qKbQFcu-Jnm5w6JKYeeyBQdDct6oxfgociUyhsjKF59Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.130422"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 151 [["active", "f"], ["updated_at", "2015-09-07 10:49:48.133430"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1229 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'pCYlOkgx3TFy3MJgRGUZNweQJuxUsBsBqWTrternCKnw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.136716"], ["target_id", 1229], ["target_type", "User"], ["token", "pCYlOkgx3TFy3MJgRGUZNweQJuxUsBsBqWTrternCKnw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.136716"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.142019"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.142019"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1230 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1230) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:48.146326"], ["target_id", 1230], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.146326"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.149959"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.149959"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1231 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1231) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:48.153650"], ["target_id", 1231], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.153650"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1231 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.158687"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.158687"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1232) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:48.161501"], ["target_id", 1232], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.161501"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.7ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1232 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.4ms) SAVEPOINT active_record_1 SQL (1.4ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 255]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.4ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.176193"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.176193"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1233) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:48.179469"], ["target_id", 1233], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-07 10:49:48.179469"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1233 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.184922"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.184922"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1234) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.187807"], ["group_id", 1], ["target_id", 1234], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.187807"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1234 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 257]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.194224"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.194224"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1235) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.197018"], ["group_id", 1], ["target_id", 1235], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.197018"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1235 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.202602"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.202602"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1236) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:48.205724"], ["target_id", 1236], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.205724"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1236 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.210604"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.210604"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.8ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1237) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:48.214813"], ["target_id", 1237], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.214813"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1237 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.220695"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.220695"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1238) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-07 10:49:48.223724"], ["target_id", 1238], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.223724"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1238) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1238 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1238 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 261]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1238 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.234260"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.234260"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1239 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.238955"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.238955"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Dy-r1g4jW-bazyXGSXnmiAQ4F0cxDCm8M2BusU6nkgJw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.240744"], ["target_id", 1240], ["target_type", "User"], ["token", "Dy-r1g4jW-bazyXGSXnmiAQ4F0cxDCm8M2BusU6nkgJw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.240744"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Dy-r1g4jW-bazyXGSXnmiAQ4F0cxDCm8M2BusU6nkgJw' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.246122"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.246122"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'sPzHJc0OWBCvtqTFatb1YQDyEQblF69_oh-CZM7RKjXA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.248076"], ["target_id", 1241], ["target_type", "User"], ["token", "sPzHJc0OWBCvtqTFatb1YQDyEQblF69_oh-CZM7RKjXA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.248076"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 154 [["active", "f"], ["updated_at", "2015-09-07 10:49:48.251454"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'sPzHJc0OWBCvtqTFatb1YQDyEQblF69_oh-CZM7RKjXA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.255066"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.255066"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'IiPW-mW07dZLlBGBG48IawXC4tJ1eEMOXRG_cZM-f6_w' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.257115"], ["target_id", 1242], ["target_type", "User"], ["token", "IiPW-mW07dZLlBGBG48IawXC4tJ1eEMOXRG_cZM-f6_w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.257115"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 155 [["active", "f"], ["updated_at", "2015-09-07 10:49:48.260157"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.263665"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:49:48.263665"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'UHXV2l1HDl5IbdzYf9XA7QTLUk67tb9JwNYtoH-Ca5lg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:49:48.266663"], ["target_id", 1243], ["target_type", "User"], ["token", "UHXV2l1HDl5IbdzYf9XA7QTLUk67tb9JwNYtoH-Ca5lg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.266663"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.272756"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-07 10:49:48.272756"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:48.275781"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1244], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.275781"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:49:48.280659"], ["email", "2@notifyuser.com"], ["updated_at", "2015-09-07 10:49:48.280659"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 10:49:48.283639"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1245], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:49:48.283639"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:52:16.032105"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:52:16.032105"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1246 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:52:16.060520"], ["state", "pending"], ["target_id", 1246], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:52:16.060520"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1246 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1246 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:52:16.113411"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:52:16.113411"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1247 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:52:16.116909"], ["state", "pending"], ["target_id", 1247], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:52:16.116909"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1247 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1247 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:53:33.570263"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:53:33.570263"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1248 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:53:33.599443"], ["state", "pending"], ["target_id", 1248], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:53:33.599443"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1248 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1248 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:53:33.658893"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:53:33.658893"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1249 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:53:33.662595"], ["state", "pending"], ["target_id", 1249], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:53:33.662595"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1249 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1249 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:53:33.670992"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:53:33.670992"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1250 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:53:33.674313"], ["state", "pending"], ["target_id", 1250], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:53:33.674313"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1250 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-07 10:53:33.681591"], ["email", "user@example.com"], ["updated_at", "2015-09-07 10:53:33.681591"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1251 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-07 10:53:33.684908"], ["state", "pending"], ["target_id", 1251], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-07 10:53:33.684908"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1251 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (3.1ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:03.658275"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:03.658275"]]  (0.6ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.4ms) Completed 200 OK in 28ms (Views: 20.8ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:03.725535"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:03.725535"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (1.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1253 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (2.0ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:03.796906"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1253], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:03.796906"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (1.0ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1253 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (7.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1253 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 50ms  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:03.890138"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:03.890138"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1254 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:03.906329"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1254], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:03.906329"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1254 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (1.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1254 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 25ms  (0.4ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:03.947238"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:03.947238"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1255 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:03.993082"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1255], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:03.993082"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1255 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.002036"], ["parent_id", 1], ["state", "pending"], ["target_id", 1255], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.002036"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1255 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1255 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 7ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:04.030533"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:04.030533"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1256 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.047920"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1256], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.047920"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1256 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.072345"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1256], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.072345"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1256 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.077358"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1256], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.077358"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1256 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 285ms  (0.4ms) ROLLBACK  (1.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:04.382382"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:04.382382"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1  (1.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1257 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.398491"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1257], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.398491"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1257 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.407669"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1257], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.407669"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1257 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.413583"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1257], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.413583"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1505"} NotifyUser::BaseNotification Load (0.9ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1257 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1505') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.6ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1257]]  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1257 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (2.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1505 [["state", "read"], ["updated_at", "2015-09-08 05:29:04.438971"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 30ms (Views: 2.3ms | ActiveRecord: 5.0ms) NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 1505 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (0.9ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:04.480795"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:04.480795"]]  (2.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1258 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.500384"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1258], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.500384"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (1.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1258 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.511406"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1258], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.511406"]]  (0.7ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1258 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.526592"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1258], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.526592"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1508"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1258 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1508') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.3ms) SAVEPOINT active_record_1 User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1258]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1258 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1508 [["state", "read"], ["updated_at", "2015-09-08 05:29:04.540285"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 12ms (Views: 0.4ms | ActiveRecord: 2.2ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1508"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1258 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1508') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 3ms (Views: 0.2ms | ActiveRecord: 2.7ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (1.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:04.553393"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:04.553393"]]  (1.0ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1259 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.567683"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1259], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.567683"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (2.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1259 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.579364"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1259], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.579364"]]  (1.0ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1259 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.593427"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1259], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.593427"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.9ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1259 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1259 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 6ms (Views: 1.7ms | ActiveRecord: 1.4ms) NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1259 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:04.614844"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:04.614844"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 8ms (Views: 5.4ms | ActiveRecord: 0.0ms)  (0.6ms) ROLLBACK  (0.5ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:04.656643"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:04.656643"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 12ms (Views: 9.1ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:04.690259"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:04.690259"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1262 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.698512"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1262], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.698512"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["1514"]} SQL (1.3ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1262 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1514')) NotifyUser::BaseNotification Load (1.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1262 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1514')) Completed 500 Internal Server Error in 18ms  (0.2ms) ROLLBACK  (1.4ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.8ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:04.734860"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:04.734860"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1263 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.755440"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1263], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.755440"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["1515"]} SQL (0.7ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1263 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1515')) NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1263 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1515')) Completed 500 Internal Server Error in 13ms  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (0.8ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:04.786372"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:04.786372"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1264 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.804368"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1264], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.804368"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1264 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1264 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.7ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.8ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1264) LIMIT 1 SQL (1.0ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:04.842493"], ["target_id", 1264], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.842493"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1264 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 42ms (Views: 3.2ms | ActiveRecord: 3.7ms) NotifyUser::Unsubscribe Load (0.6ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1264 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:04.862285"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:04.862285"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1265 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.868907"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1265], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.868907"]]  (0.8ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (1.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1265 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.6ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1265 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1265 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 13ms (Views: 5.8ms | ActiveRecord: 1.1ms) NotifyUser::Unsubscribe Load (1.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1265 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.6ms) ROLLBACK  (0.3ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (1.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:04.914213"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:04.914213"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1266 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:04.938410"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1266], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.938410"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1266 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1266) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:04.949096"], ["target_id", 1266], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:04.949096"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1266 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 10ms (ActiveRecord: 2.1ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.7ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:04.983392"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:04.983392"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1267 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.1ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:05.001686"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1267], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.001686"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.7ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1267) LIMIT 1 SQL (1.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:05.017303"], ["target_id", 1267], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.017303"]]  (0.6ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.6ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1267 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 264]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 17ms (ActiveRecord: 1.2ms) NotifyUser::Unsubscribe Load (0.8ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.8ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.062545"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.062545"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1268 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:05.072772"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1268], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.072772"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.7ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1268 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.5ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (1.0ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'wfDwh2CWxBk7LNcRz9TM2QfMsRx1sdC7t2R8R_VTS-_w' LIMIT 1 SQL (0.9ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.091055"], ["target_id", 1268], ["target_type", "User"], ["token", "wfDwh2CWxBk7LNcRz9TM2QfMsRx1sdC7t2R8R_VTS-_w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.091055"]]  (0.4ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"wfDwh2CWxBk7LNcRz9TM2QfMsRx1sdC7t2R8R_VTS-_w"} NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'wfDwh2CWxBk7LNcRz9TM2QfMsRx1sdC7t2R8R_VTS-_w' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'wfDwh2CWxBk7LNcRz9TM2QfMsRx1sdC7t2R8R_VTS-_w' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1268]]  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1268) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:05.109711"], ["target_id", 1268], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.109711"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 157 [["active", "f"], ["updated_at", "2015-09-08 05:29:05.111438"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.4ms | ActiveRecord: 2.5ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.116851"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.116851"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1269 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.126440"], ["state", "pending"], ["target_id", 1269], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.126440"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1269 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1269 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (1.9ms) ROLLBACK  (0.5ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.142496"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.142496"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1270 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.149835"], ["state", "pending"], ["target_id", 1270], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.149835"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1270 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1270 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.161241"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.161241"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1271 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.164834"], ["state", "pending"], ["target_id", 1271], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.164834"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1271 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.9ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.178545"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.178545"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1272 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.182546"], ["state", "pending"], ["target_id", 1272], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.182546"]]  (0.9ms) RELEASE SAVEPOINT active_record_1  (1.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1272 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.7ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 29.4ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.6ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.8ms NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) ROLLBACK  (0.4ms) BEGIN NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (1.1ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 10.8ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.567719"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.567719"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1273 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.577853"], ["state", "pending"], ["target_id", 1273], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.577853"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1273 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.8ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.588297"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.588297"]]  (0.7ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SAVEPOINT active_record_1  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1274 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.603925"], ["state", "pending"], ["target_id", 1274], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.603925"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1274 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.611740"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.611740"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1275 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.615384"], ["state", "pending"], ["target_id", 1275], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.615384"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1275 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.9ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.629571"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.629571"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1276 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.633118"], ["state", "pending"], ["target_id", 1276], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.633118"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1276 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.7ms) ROLLBACK  (0.3ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.645919"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.645919"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1277 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.652118"], ["state", "pending"], ["target_id", 1277], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.652118"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1277 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.659432"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.659432"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1278 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.664992"], ["state", "pending"], ["target_id", 1278], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.664992"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.6ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.673753"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.673753"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1279 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.679520"], ["state", "pending"], ["target_id", 1279], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.679520"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.683760"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.683760"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1280 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.0ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.693325"], ["state", "pending"], ["target_id", 1280], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.693325"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1280 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1532 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-08 05:29:05.700479"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.707967"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.707967"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1281 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.711384"], ["state", "pending"], ["target_id", 1281], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.711384"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1281 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1533 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-08 05:29:05.714512"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.9ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.725136"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.725136"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1282 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.731778"], ["state", "pending"], ["target_id", 1282], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.731778"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1282 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1534 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-08 05:29:05.735655"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.741561"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.741561"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1283 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.745818"], ["state", "pending"], ["target_id", 1283], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.745818"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1283 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1535 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-08 05:29:05.749221"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (2.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.5ms) ROLLBACK  (0.3ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.764870"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.764870"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1284 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.768691"], ["state", "pending"], ["target_id", 1284], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.768691"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1284 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) RELEASE SAVEPOINT active_record_1  (0.8ms) ROLLBACK  (0.4ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.783704"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.783704"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.8ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.790899"], ["state", "pending"], ["target_id", 1285], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.790899"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.7ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1537 [["state", "sent"], ["updated_at", "2015-09-08 05:29:05.805462"]]  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1537 [["sent_time", "2015-09-08 05:29:05.807590"], ["updated_at", "2015-09-08 05:29:05.810555"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.815994"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.815994"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.824827"], ["state", "pending"], ["target_id", 1286], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.824827"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1286 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1538)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1538 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:05.833201"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1538]] User Load (0.9ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1286]] NewPostNotification Load (0.9ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1286 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.5ms) SAVEPOINT active_record_1 User Load (0.6ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1286]]  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1538 [["sent_time", "2015-09-08 05:29:05.847038"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:05.852454"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1538]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1286]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1286 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Nrls7Vn-Lno-tU4d7p0T2QONbx73jXx2J8j2vw7cKWeQ' LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.865457"], ["target_id", 1286], ["target_type", "User"], ["token", "Nrls7Vn-Lno-tU4d7p0T2QONbx73jXx2J8j2vw7cKWeQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.865457"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.7ms Sent mail to user@example.com (9.7ms) Date: Tue, 08 Sep 2015 15:29:05 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ee7221d5eeb_f263fe2c9c6020053351@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.882343"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.882343"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1287 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.8ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.888572"], ["state", "pending_as_aggregation_parent"], ["target_id", 1287], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.888572"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1287 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.897177"], ["state", "pending"], ["target_id", 1287], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.897177"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1287 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1287 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1540)  (1.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.909064"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.909064"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1288 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.912599"], ["state", "pending"], ["target_id", 1288], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.912599"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1288 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1288 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1541 [["state", "sent"], ["updated_at", "2015-09-08 05:29:05.917374"]]  (1.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1288 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1541 [["sent_time", "2015-09-08 05:29:05.919190"], ["updated_at", "2015-09-08 05:29:05.926159"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1541]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1288]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1288 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1288 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (1.1ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1288 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.7ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.7ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '7H0QwVXzOlV43eP6ihfVggGxltd5IcrVzZ2cfyQP9cZQ' LIMIT 1 SQL (0.6ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.941739"], ["target_id", 1288], ["target_type", "User"], ["token", "7H0QwVXzOlV43eP6ihfVggGxltd5IcrVzZ2cfyQP9cZQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.941739"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 12.9ms Sent mail to user@example.com (3.7ms) Date: Tue, 08 Sep 2015 15:29:05 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ee7221e7e01_f263fe2c9c6020053425@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.956040"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.956040"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1289 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.959883"], ["state", "pending"], ["target_id", 1289], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.959883"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1289 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1542 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-08 05:29:05.963051"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.967424"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.967424"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1290 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:05.976394"], ["state", "pending"], ["target_id", 1290], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:05.976394"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1290) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:05.980310"], ["target_id", 1290], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-08 05:29:05.980310"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1543]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1290]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1290 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (3.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1290 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.5ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:05.998691"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:05.998691"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1291 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:06.005842"], ["state", "pending"], ["target_id", 1291], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.005842"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1544]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1291]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1291 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1291 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.021241"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.021241"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.0ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.0ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:06.035861"], ["state", "pending"], ["target_id", 1292], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.035861"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1545 [["state", "sent"], ["updated_at", "2015-09-08 05:29:06.045262"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1545 [["sent_time", "2015-09-08 05:29:06.047143"], ["updated_at", "2015-09-08 05:29:06.049420"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1545]] User Load (0.5ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1292]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (4.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1292 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '_1EEiWecY9hTXSKaju2a3QwqcydG9f6r9Qzl5k4O4KHg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:06.076657"], ["target_id", 1292], ["target_type", "User"], ["token", "_1EEiWecY9hTXSKaju2a3QwqcydG9f6r9Qzl5k4O4KHg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.076657"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 15.7ms Sent mail to user@example.com (2.3ms) Date: Tue, 08 Sep 2015 15:29:06 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ee722213e82_f263fe2c9c6020053521@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.9ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.087374"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.087374"]]  (0.7ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1293 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:06.096387"], ["state", "pending"], ["target_id", 1293], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.096387"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1546]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1293]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1293 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1293 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.3ms) ROLLBACK  (0.3ms) BEGIN  (0.6ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.112771"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.112771"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1294 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.0ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:06.120079"], ["state", "pending"], ["target_id", 1294], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.120079"]]  (0.8ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1547]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1294]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1294 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1294]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1294 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1547 [["sent_time", "2015-09-08 05:29:06.130905"], ["state", "sent"], ["updated_at", "2015-09-08 05:29:06.133351"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1294 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.6ms) ROLLBACK  (0.5ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (0.9ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.149126"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.149126"]]  (1.5ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1295 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:06.158335"], ["state", "pending"], ["target_id", 1295], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.158335"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1295 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:06.162350"], ["state", "pending"], ["target_id", 1295], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.162350"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1549]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1295]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1295 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1295]]  (1.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1295 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1549 [["sent_time", "2015-09-08 05:29:06.167319"], ["state", "sent"], ["updated_at", "2015-09-08 05:29:06.173389"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1295]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1295 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1548 [["sent_time", "2015-09-08 05:29:06.178974"], ["state", "sent"], ["updated_at", "2015-09-08 05:29:06.181467"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1295 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1295 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.4ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.198639"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.198639"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1296 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:06.204910"], ["state", "read"], ["target_id", 1296], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.204910"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1550]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1296]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1296 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.212557"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.212557"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1297 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1297 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (1.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.218214"], ["group_id", 2], ["state", "pending"], ["target_id", 1297], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.218214"]]  (0.7ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1551]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1297]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1297 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1297]]  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1297 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1297 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1551 [["sent_time", "2015-09-08 05:29:06.232155"], ["state", "sent"], ["updated_at", "2015-09-08 05:29:06.237959"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1297 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1297 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1551]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1297]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1297 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1297 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1297 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1297 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Vs31oa8ccmZbStvuCfVKDAreW1ftBGsHeLsFQ6vYiLtA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:06.252547"], ["target_id", 1297], ["target_type", "User"], ["token", "Vs31oa8ccmZbStvuCfVKDAreW1ftBGsHeLsFQ6vYiLtA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.252547"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.3ms Sent mail to user@example.com (2.2ms) Date: Tue, 08 Sep 2015 15:29:06 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <55ee72223eb3e_f263fe2c9c60200536ae@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.3ms) BEGIN  (1.3ms) SAVEPOINT active_record_1 SQL (1.1ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.265857"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.265857"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1298 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1298 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.0ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.282317"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1298], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.282317"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1298 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1298 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.8ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1552 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:06.291170"]]  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1298 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1298 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.0ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1552 [["sent_time", "2015-09-08 05:29:06.296441"], ["updated_at", "2015-09-08 05:29:06.301774"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1552]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.311823"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.311823"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1299 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1299 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.316158"], ["group_id", 1], ["state", "pending"], ["target_id", 1299], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.316158"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1299 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1553) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.8ms) ROLLBACK  (0.6ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.328957"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.328957"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1300 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1300 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.333970"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1300], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.333970"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1300 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1300 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.343074"], ["group_id", 1], ["state", "pending"], ["target_id", 1300], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.343074"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1300 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1555) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.4ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.354592"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.354592"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1301 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1301 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.359394"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1301], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.359394"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1301 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1301 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.364011"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1301], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.364011"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1301 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1301 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.1ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.369288"], ["group_id", 1], ["state", "pending"], ["target_id", 1301], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.369288"]]  (0.7ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1301 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1558) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.381212"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.381212"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1302 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1302 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.8ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.387738"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 1302], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.387738"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1302 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1302 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.399733"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 1302], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.399733"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1302 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1302 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.407302"], ["group_id", 1], ["state", "pending"], ["target_id", 1302], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.407302"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1302 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1561) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.413682"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.413682"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1303 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1303 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.420254"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1303], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.420254"]]  (0.7ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1303 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1303 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.430355"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1303], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.430355"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1303 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1303 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.435727"], ["group_id", 1], ["state", "pending"], ["target_id", 1303], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.435727"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1303 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1564) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.6ms) ROLLBACK  (0.4ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.450256"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.450256"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1304 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1304 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 19:29:06.453263"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1304], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.457436"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1304 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-07 05:29:06.459401') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1304 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-07 05:29:06.459401') ORDER BY created_at DESC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1304 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1304 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-08 05:29:06.464903"], ["group_id", 1], ["parent_id", 1565], ["state", "pending"], ["target_id", 1304], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.464903"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.469116"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.469116"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1305 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1305 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:29:06.471230"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1305], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.479288"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1305 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-07 05:29:06.481630')  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1305 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1305 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.513565"], ["group_id", 1], ["state", "pending"], ["target_id", 1305], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.513565"]]  (1.2ms) RELEASE SAVEPOINT active_record_1  (1.7ms) ROLLBACK  (0.1ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.525734"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.525734"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1306 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1306 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-07 04:29:06.527338"], ["group_id", 1], ["state", "pending"], ["target_id", 1306], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.531942"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1306 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-07 05:29:06.534754')  (0.2ms) SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1306 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1306 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.544849"], ["group_id", 1], ["state", "pending"], ["target_id", 1306], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.544849"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.8ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.558527"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.558527"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1  (1.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1307 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1307 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.573553"], ["group_id", 1], ["state", "pending"], ["target_id", 1307], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.573553"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1307 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1571) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1307 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1571) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.9ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.594613"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.594613"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1308 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1308 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.607520"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1308], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.607520"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1308 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1308 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1572 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:06.612056"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1308 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1308 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1572 [["sent_time", "2015-09-08 05:29:06.613605"], ["updated_at", "2015-09-08 05:29:06.616578"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (1.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1308 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1308 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.628335"], ["group_id", 1], ["state", "pending"], ["target_id", 1308], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.628335"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1308 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1573) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1308 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1573) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.5ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.645426"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.645426"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.655164"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1309], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.655164"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1574 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:06.660109"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1574 [["sent_time", "2015-09-08 05:29:06.661656"], ["updated_at", "2015-09-08 05:29:06.665030"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.670813"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1309], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.670813"]]  (0.7ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1575 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:06.680759"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1575 [["sent_time", "2015-09-08 05:29:06.682188"], ["updated_at", "2015-09-08 05:29:06.685044"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (1.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.8ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.698276"], ["group_id", 1], ["state", "pending"], ["target_id", 1309], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.698276"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1309 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1576) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1309 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1576) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:06.710685"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:06.710685"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.715388"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1310], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.715388"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.5ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1577 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:06.721206"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1577 [["sent_time", "2015-09-08 05:29:06.727168"], ["updated_at", "2015-09-08 05:29:06.730709"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.736378"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1310], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.736378"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1578 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:06.751515"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1578 [["sent_time", "2015-09-08 05:29:06.756273"], ["updated_at", "2015-09-08 05:29:06.760219"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.766878"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1310], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.766878"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1579 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:06.774124"]]  (2.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1579 [["sent_time", "2015-09-08 05:29:06.775627"], ["updated_at", "2015-09-08 05:29:06.785889"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.793944"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1310], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.793944"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1580 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:06.802466"]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.0ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1580 [["sent_time", "2015-09-08 05:29:06.805173"], ["updated_at", "2015-09-08 05:29:06.811764"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.828297"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1310], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.828297"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1581 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:06.835218"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1581 [["sent_time", "2015-09-08 05:29:06.836764"], ["updated_at", "2015-09-08 05:29:06.840469"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.9ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.847059"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1310], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.847059"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1582 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:06.861803"]]  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1582 [["sent_time", "2015-09-08 05:29:06.863680"], ["updated_at", "2015-09-08 05:29:06.869533"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.887699"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1310], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.887699"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1583 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:06.893706"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1583 [["sent_time", "2015-09-08 05:29:06.895039"], ["updated_at", "2015-09-08 05:29:06.897963"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.1ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.904918"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1310], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.904918"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1584 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:06.914365"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1584 [["sent_time", "2015-09-08 05:29:06.915714"], ["updated_at", "2015-09-08 05:29:06.918767"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SAVEPOINT active_record_1  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.937129"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1310], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.937129"]]  (0.8ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1585 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:06.948304"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.5ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1585 [["sent_time", "2015-09-08 05:29:06.949807"], ["updated_at", "2015-09-08 05:29:06.954074"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1  (1.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.972371"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1310], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.972371"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1586 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:06.979626"]]  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1586 [["sent_time", "2015-09-08 05:29:06.981767"], ["updated_at", "2015-09-08 05:29:06.987111"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:06.995770"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1310], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:06.995770"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1587 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:07.003050"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1587 [["sent_time", "2015-09-08 05:29:07.004843"], ["updated_at", "2015-09-08 05:29:07.008873"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:07.014568"], ["group_id", 1], ["state", "pending"], ["target_id", 1310], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.014568"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1310 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1588) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (1.0ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1310 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1588) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.5ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.029266"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.029266"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1311 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1311 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:07.036402"], ["group_id", 1], ["state", "pending"], ["target_id", 1311], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.036402"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1311 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (2.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1311 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (1.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1311 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1589)  (0.5ms) SAVEPOINT active_record_1  (2.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1311 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1311 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1589 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:07.075023"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.7ms) ROLLBACK  (1.9ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.092905"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.092905"]]  (0.7ms) RELEASE SAVEPOINT active_record_1  (3.9ms) SAVEPOINT active_record_1  (2.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1312 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (3.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1312 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.7ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:07.117023"], ["group_id", 1], ["state", "pending"], ["target_id", 1312], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.117023"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1312 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1312 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1312 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1590)  (0.3ms) SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1312 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (2.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1312 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1590 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:07.142596"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.150216"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.150216"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1313 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1313 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:07.159986"], ["group_id", 1], ["state", "pending"], ["target_id", 1313], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.159986"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1313 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1313 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1313 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1591)  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1313 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1313 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1591 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:07.174913"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1591]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.181400"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.181400"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1314 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1314 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:07.186020"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1314], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.186020"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1314 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1314 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:31:07.186020"], ["group_id", 1], ["state", "pending"], ["target_id", 1314], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.198136"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1314 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1314 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (2.2ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1314 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1593)  (1.0ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1314 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1314 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.9ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1593 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-08 05:29:07.222000"]]  (1.5ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.237711"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.237711"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1315 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1315 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.1ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:07.251123"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1315], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.251123"]]  (0.8ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1315 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-07 05:29:07.262819') NewPostNotification Load (5.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1315 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-07 05:29:07.262819') ORDER BY created_at DESC LIMIT 1  (0.9ms) SAVEPOINT active_record_1  (1.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1315 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1315 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-08 05:31:07.251123"], ["group_id", 1], ["parent_id", 1594], ["state", "pending"], ["target_id", 1315], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.293051"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (1.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1595]]  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.305596"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.305596"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:07.314056"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1316], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.314056"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:07.323460"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1316], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.323460"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (1.2ms) SAVEPOINT active_record_1  (1.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:07.340842"], ["group_id", 1], ["state", "pending"], ["target_id", 1316], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.340842"]]  (0.8ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1316 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1598)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (1.1ms) SAVEPOINT active_record_1 SQL (1.1ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.356685"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.356685"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1317 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1317 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:07.365335"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1317], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.365335"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1317 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1317 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (2.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:07.373030"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1317], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.373030"]]  (0.8ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1317 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1317 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:07.391241"], ["group_id", 1], ["state", "pending"], ["target_id", 1317], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.391241"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1317 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1317 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1317 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1601) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1601]]  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (1.0ms) SAVEPOINT active_record_1 SQL (1.9ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.403756"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.403756"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1318 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.417837"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.417837"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1319 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1319 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (1.4ms) ROLLBACK  (0.5ms) BEGIN  (0.6ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.438188"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.438188"]]  (0.9ms) RELEASE SAVEPOINT active_record_1  (1.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1320 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) ROLLBACK  (0.4ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.467303"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.467303"]]  (0.8ms) RELEASE SAVEPOINT active_record_1  (1.0ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1321 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.480773"], ["state", "pending"], ["target_id", 1321], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.480773"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1321) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:07.485220"], ["target_id", 1321], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.485220"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1321 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) ROLLBACK  (0.5ms) BEGIN  (0.6ms) SAVEPOINT active_record_1 SQL (1.0ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.502518"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.502518"]]  (1.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1322 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.516207"], ["state", "pending"], ["target_id", 1322], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.516207"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1322 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) ROLLBACK  (0.5ms) BEGIN  (1.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.537677"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.537677"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1323 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.9ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.547942"], ["state", "pending"], ["target_id", 1323], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.547942"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.8ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1323) LIMIT 1 SQL (0.6ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:07.558165"], ["target_id", 1323], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-08 05:29:07.558165"]]  (0.8ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1323 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1323 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.573233"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.573233"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1324 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.578373"], ["state", "pending"], ["target_id", 1324], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.578373"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1324 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1324 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.587338"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.587338"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.6ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.599446"], ["state", "pending"], ["target_id", 1325], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.599446"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.9ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1325) LIMIT 1 SQL (1.0ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.614910"], ["group_id", 1], ["target_id", 1325], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.614910"]]  (1.0ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) ROLLBACK TO SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) ROLLBACK  (0.4ms) BEGIN  (0.9ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.641614"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.641614"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1326 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.1ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.649834"], ["state", "pending"], ["target_id", 1326], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.649834"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (1.8ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1326) LIMIT 1 SQL (0.9ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:07.667096"], ["target_id", 1326], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.667096"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1326 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) ROLLBACK TO SAVEPOINT active_record_1  (2.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1326 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) ROLLBACK  (0.4ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (1.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.690079"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.690079"]]  (0.9ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.700401"], ["state", "pending"], ["target_id", 1327], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.700401"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (2.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.0ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1608 [["group_id", 1], ["updated_at", "2015-09-08 05:29:07.712999"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (3.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) ROLLBACK  (1.1ms) BEGIN  (0.7ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.745724"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.745724"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1328 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.751001"], ["state", "pending"], ["target_id", 1328], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.751001"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1609]] User Load (0.8ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1328]]  (1.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1328 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1328 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.768957"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.768957"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1329 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.777054"], ["state", "pending"], ["target_id", 1329], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.777054"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1329) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:07.788655"], ["target_id", 1329], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-08 05:29:07.788655"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1610]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1329]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1329 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1329 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.798244"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.798244"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1330 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.803535"], ["state", "pending"], ["target_id", 1330], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.803535"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1330) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.807231"], ["group_id", 1], ["target_id", 1330], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.807231"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1330 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1611]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1330]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1330 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.819936"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.819936"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (1.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1331 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.832081"], ["state", "pending"], ["target_id", 1331], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.832081"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1331 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1331 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.847402"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.847402"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1332 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.851067"], ["state", "pending"], ["target_id", 1332], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.851067"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1332) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:07.855569"], ["target_id", 1332], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-08 05:29:07.855569"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1332 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1332 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.4ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.863425"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.863425"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1333 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.868738"], ["state", "pending"], ["target_id", 1333], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.868738"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1333) LIMIT 1 SQL (1.1ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.874195"], ["group_id", 1], ["target_id", 1333], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.874195"]]  (0.9ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1333 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK TO SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1333 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.893844"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.893844"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1334 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.898465"], ["state", "pending"], ["target_id", 1334], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.898465"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1334 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (1.6ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'CxGoc8_zwez5LSyANIFS-wbTvORiFMjFZAS7mb1tsF5w' LIMIT 1 SQL (0.5ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.903086"], ["target_id", 1334], ["target_type", "User"], ["token", "CxGoc8_zwez5LSyANIFS-wbTvORiFMjFZAS7mb1tsF5w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.903086"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.3ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.918376"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.918376"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (2.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1335 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.934833"], ["state", "pending"], ["target_id", 1335], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.934833"]]  (0.4ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.8ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1335 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.3ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.5ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'vLm3f1SI7pGdginc0TkNGw6hMYLkh0ZkmzcDdrD0cZbQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.946656"], ["target_id", 1335], ["target_type", "User"], ["token", "vLm3f1SI7pGdginc0TkNGw6hMYLkh0ZkmzcDdrD0cZbQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.946656"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1335 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.958003"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.958003"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1336 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.963661"], ["state", "pending"], ["target_id", 1336], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.963661"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1336 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'unYOjfNtS6tOuIf07tYQLwe3rI50Uq4YWASKDNiZmGQA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.968140"], ["target_id", 1336], ["target_type", "User"], ["token", "unYOjfNtS6tOuIf07tYQLwe3rI50Uq4YWASKDNiZmGQA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.968140"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 164 [["active", "f"], ["updated_at", "2015-09-08 05:29:07.971157"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1336 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '7wkH__n2JqobeAkz-ALUiQ4GgTV2w7AXZEtP1b4q4fdg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:07.974947"], ["target_id", 1336], ["target_type", "User"], ["token", "7wkH__n2JqobeAkz-ALUiQ4GgTV2w7AXZEtP1b4q4fdg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.974947"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.982515"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.982515"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1337 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1337) LIMIT 1 SQL (0.5ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:07.987975"], ["target_id", 1337], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:07.987975"]]  (0.7ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (1.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:07.996023"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:07.996023"]]  (0.4ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.9ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1338 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.4ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.6ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1338) LIMIT 1 SQL (1.0ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:08.010700"], ["target_id", 1338], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:08.010700"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (1.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.6ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1338 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:08.031247"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:08.031247"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1339) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:08.035782"], ["target_id", 1339], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:08.035782"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 277]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:08.044902"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:08.044902"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1340) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:08.048492"], ["target_id", 1340], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-08 05:29:08.048492"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:08.055414"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:08.055414"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1341) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:08.058597"], ["group_id", 1], ["target_id", 1341], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:08.058597"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1341 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 279]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:08.067323"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:08.067323"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (1.1ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1342) LIMIT 1 SQL (1.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:08.073593"], ["group_id", 1], ["target_id", 1342], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:08.073593"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1342 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:08.086603"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:08.086603"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.6ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1343) LIMIT 1 SQL (0.7ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:08.092489"], ["target_id", 1343], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:08.092489"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1343 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.4ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:08.100789"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:08.100789"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.7ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1344) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:08.105314"], ["target_id", 1344], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:08.105314"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1344 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:08.115042"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:08.115042"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1345) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-08 05:29:08.119422"], ["target_id", 1345], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:08.119422"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1345) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (1.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1345 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (1.2ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1345 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.6ms) SAVEPOINT active_record_1 SQL (1.8ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 283]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1345 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:08.145386"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:08.145386"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1346 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:08.152641"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:08.152641"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'j1od-DzRHY4KwkV_ObVJDQiZkhzK2ZqNOimwnzGHNMgQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:08.155209"], ["target_id", 1347], ["target_type", "User"], ["token", "j1od-DzRHY4KwkV_ObVJDQiZkhzK2ZqNOimwnzGHNMgQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:08.155209"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'j1od-DzRHY4KwkV_ObVJDQiZkhzK2ZqNOimwnzGHNMgQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:08.161671"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:08.161671"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'TzNMb95GAQVpjKez3B2uvQxmr2o9m5aX42nHwE_LtqQA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:08.163867"], ["target_id", 1348], ["target_type", "User"], ["token", "TzNMb95GAQVpjKez3B2uvQxmr2o9m5aX42nHwE_LtqQA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:08.163867"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 167 [["active", "f"], ["updated_at", "2015-09-08 05:29:08.168282"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'TzNMb95GAQVpjKez3B2uvQxmr2o9m5aX42nHwE_LtqQA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:08.172235"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:08.172235"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'IyT96zVjEpD2oJbqcshdMAIONm_hHuV58-2jX8LF_ZtA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:08.173999"], ["target_id", 1349], ["target_type", "User"], ["token", "IyT96zVjEpD2oJbqcshdMAIONm_hHuV58-2jX8LF_ZtA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:08.173999"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 168 [["active", "f"], ["updated_at", "2015-09-08 05:29:08.177036"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:08.180002"], ["email", "user@example.com"], ["updated_at", "2015-09-08 05:29:08.180002"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'adv5Lvi1MyckRyPZ-AxDNw0J5zMczYuhlJeA9nj_rUuA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-08 05:29:08.181894"], ["target_id", 1350], ["target_type", "User"], ["token", "adv5Lvi1MyckRyPZ-AxDNw0J5zMczYuhlJeA9nj_rUuA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:08.181894"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:08.193455"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-08 05:29:08.193455"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1351 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:08.196791"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1351], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:08.196791"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-08 05:29:08.201644"], ["email", "2@notifyuser.com"], ["updated_at", "2015-09-08 05:29:08.201644"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1352 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-08 05:29:08.205857"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1352], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-08 05:29:08.205857"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (19.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:46.932797"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:46.932797"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.3ms) Completed 200 OK in 26ms (Views: 19.7ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.003555"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.003555"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (21.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1354 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (4.7ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.069817"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1354], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.069817"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1354 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (2.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1354 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 16ms  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.100594"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.100594"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1355 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.106282"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1355], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.106282"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1355 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1355 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.119456"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.119456"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1356 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.125443"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1356], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.125443"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1356 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.128798"], ["parent_id", 1], ["state", "pending"], ["target_id", 1356], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.128798"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1356 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1356 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.143388"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.143388"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1357 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.149937"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1357], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.149937"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1357 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.153485"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1357], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.153485"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1357 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.156711"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1357], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.156711"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1357 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 165ms  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.333757"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.333757"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1358 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.341413"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1358], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.341413"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1358 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.350407"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1358], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.350407"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1358 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.354613"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1358], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.354613"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1627"} NotifyUser::BaseNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1358 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1627') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1358]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1358 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1627 [["state", "read"], ["updated_at", "2015-09-28 03:37:47.369183"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 15ms (Views: 1.7ms | ActiveRecord: 1.9ms) NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 1627 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.392837"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.392837"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1359 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.399730"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1359], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.399730"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1359 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.403750"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1359], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.403750"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1359 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.407573"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1359], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.407573"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1630"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1359 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1630') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1359]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1359 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1630 [["state", "read"], ["updated_at", "2015-09-28 03:37:47.417074"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.3ms | ActiveRecord: 1.6ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1630"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1359 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1630') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.2ms | ActiveRecord: 2.1ms)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.428736"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.428736"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1360 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.434757"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1360], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.434757"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1360 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.438396"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1360], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.438396"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1360 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.441936"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1360], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.441936"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1360 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1360 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 4ms (Views: 0.9ms | ActiveRecord: 1.0ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1360 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.455590"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.455590"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 3ms (Views: 1.9ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.473410"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.473410"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 3ms (Views: 1.9ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.492239"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.492239"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1363 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.499188"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1363], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.499188"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["1636"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1363 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1636')) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1363 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1636')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.515580"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.515580"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1364 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.523611"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1364], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.523611"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["1637"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1364 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1637')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1364 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1637')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.541648"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.541648"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1365 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.549795"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1365], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.549795"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1365 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1365 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1365) LIMIT 1 SQL (19.7ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:47.573400"], ["target_id", 1365], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.573400"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1365 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 42ms (Views: 2.2ms | ActiveRecord: 21.2ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1365 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.606834"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.606834"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1366 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.613059"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1366], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.613059"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1366 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1366 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1366 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 16ms (Views: 12.1ms | ActiveRecord: 0.7ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1366 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.642286"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.642286"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1367 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.648913"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1367], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.648913"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1367 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1367) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:47.656045"], ["target_id", 1367], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.656045"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1367 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 7ms (ActiveRecord: 1.4ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.664855"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.664855"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1368 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.670468"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1368], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.670468"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1368) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:47.673663"], ["target_id", 1368], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.673663"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1368 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 286]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 4ms (ActiveRecord: 1.1ms) NotifyUser::Unsubscribe Load (1.1ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.687893"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.687893"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1369 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:47.694551"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1369], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.694551"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (1.2ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1369 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ubkW_AZeF0tDLQOK4AiQzwYuudMM7JtZLM2_Aqbihs5w' LIMIT 1 SQL (1.5ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:47.705540"], ["target_id", 1369], ["target_type", "User"], ["token", "ubkW_AZeF0tDLQOK4AiQzwYuudMM7JtZLM2_Aqbihs5w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.705540"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"ubkW_AZeF0tDLQOK4AiQzwYuudMM7JtZLM2_Aqbihs5w"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ubkW_AZeF0tDLQOK4AiQzwYuudMM7JtZLM2_Aqbihs5w' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ubkW_AZeF0tDLQOK4AiQzwYuudMM7JtZLM2_Aqbihs5w' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.5ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1369]]  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1369) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:47.716997"], ["target_id", 1369], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.716997"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 170 [["active", "f"], ["updated_at", "2015-09-28 03:37:47.718585"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.4ms | ActiveRecord: 2.4ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.724734"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.724734"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1370 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:47.728553"], ["state", "pending"], ["target_id", 1370], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.728553"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1370 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1370 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.739340"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.739340"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1371 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:47.742769"], ["state", "pending"], ["target_id", 1371], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.742769"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1371 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1371 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.753815"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.753815"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1372 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:47.757228"], ["state", "pending"], ["target_id", 1372], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.757228"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1372 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:47.765764"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:47.765764"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1373 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:47.769484"], ["state", "pending"], ["target_id", 1373], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:47.769484"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1373 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 28.1ms NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.6ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.7ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.3ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.7ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.055424"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.055424"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1374 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.058825"], ["state", "pending"], ["target_id", 1374], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.058825"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1374 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.065155"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.065155"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1375 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.068349"], ["state", "pending"], ["target_id", 1375], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.068349"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1375 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.074539"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.074539"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1376 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.079391"], ["state", "pending"], ["target_id", 1376], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.079391"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1376 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.087227"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.087227"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1377 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.090540"], ["state", "pending"], ["target_id", 1377], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.090540"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1377 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.096947"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.096947"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1378 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.100232"], ["state", "pending"], ["target_id", 1378], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.100232"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1378 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.105819"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.105819"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1379 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.109115"], ["state", "pending"], ["target_id", 1379], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.109115"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.113208"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.113208"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1380 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.116484"], ["state", "pending"], ["target_id", 1380], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.116484"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.120409"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.120409"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1381 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.123713"], ["state", "pending"], ["target_id", 1381], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.123713"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1381 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1654 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:37:48.127445"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.133405"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.133405"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1382 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.136679"], ["state", "pending"], ["target_id", 1382], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.136679"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1382 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1655 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:37:48.139949"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.145372"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.145372"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1383 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.148870"], ["state", "pending"], ["target_id", 1383], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.148870"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1383 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1656 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:37:48.152067"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.157346"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.157346"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1384 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.160565"], ["state", "pending"], ["target_id", 1384], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.160565"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1384 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1657 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:37:48.163777"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.168803"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.168803"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1385 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.171810"], ["state", "pending"], ["target_id", 1385], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.171810"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1385 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.177533"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.177533"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1386 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.181728"], ["state", "pending"], ["target_id", 1386], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.181728"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1386 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1386 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1659 [["state", "sent"], ["updated_at", "2015-09-28 03:37:48.187120"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1386 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1659 [["sent_time", "2015-09-28 03:37:48.188292"], ["updated_at", "2015-09-28 03:37:48.189628"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.193980"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.193980"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1387 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.197155"], ["state", "pending"], ["target_id", 1387], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.197155"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1387 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1387 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1660)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1387 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1660 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.202997"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1660]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1387]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1387 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) SAVEPOINT active_record_1 User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1387]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1387 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1660 [["sent_time", "2015-09-28 03:37:48.209363"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.216368"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1387 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1660]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1387]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1387 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1387 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1387 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'HnC3UTvfWwouCRhVdYvNPAeGG_znk9SlUIa0SSOpzkTA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.226920"], ["target_id", 1387], ["target_type", "User"], ["token", "HnC3UTvfWwouCRhVdYvNPAeGG_znk9SlUIa0SSOpzkTA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.226920"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.5ms Sent mail to user@example.com (5.8ms) Date: Mon, 28 Sep 2015 13:37:48 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b60c390aa_1059c3ff550c601f8156ba@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.239532"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.239532"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1388 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.242725"], ["state", "pending_as_aggregation_parent"], ["target_id", 1388], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.242725"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1388 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.246069"], ["state", "pending"], ["target_id", 1388], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.246069"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1388 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1388 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1662)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.253063"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.253063"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1389 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.256229"], ["state", "pending"], ["target_id", 1389], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.256229"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1389 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1389 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1663 [["state", "sent"], ["updated_at", "2015-09-28 03:37:48.260149"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1389 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1663 [["sent_time", "2015-09-28 03:37:48.261325"], ["updated_at", "2015-09-28 03:37:48.262687"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1663]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1389]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1389 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1389 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1389 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'F4trYL4K6_SLst8yroWe-AugI0A9m8VKcOuiyxbMqJTg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.271985"], ["target_id", 1389], ["target_type", "User"], ["token", "F4trYL4K6_SLst8yroWe-AugI0A9m8VKcOuiyxbMqJTg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.271985"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.0ms Sent mail to user@example.com (2.0ms) Date: Mon, 28 Sep 2015 13:37:48 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b60c43623_1059c3ff550c601f815714@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.280717"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.280717"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1390 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.283936"], ["state", "pending"], ["target_id", 1390], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.283936"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1390 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1664 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 03:37:48.287044"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.291362"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.291362"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1391 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.294487"], ["state", "pending"], ["target_id", 1391], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.294487"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1391) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:48.297195"], ["target_id", 1391], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:37:48.297195"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1665]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1391]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1391 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1391 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.305492"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.305492"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1392 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.308766"], ["state", "pending"], ["target_id", 1392], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.308766"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1666]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1392]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1392 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1392 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.316694"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.316694"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1393 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.320137"], ["state", "pending"], ["target_id", 1393], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.320137"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1393 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1393 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1667 [["state", "sent"], ["updated_at", "2015-09-28 03:37:48.324610"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1393 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1667 [["sent_time", "2015-09-28 03:37:48.325790"], ["updated_at", "2015-09-28 03:37:48.327272"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1667]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1393]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1393 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1393 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1393 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'MwzD5wfgA3VycqzVmOlOjQC_u2Aph3cg0Wven60AjiXQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.336929"], ["target_id", 1393], ["target_type", "User"], ["token", "MwzD5wfgA3VycqzVmOlOjQC_u2Aph3cg0Wven60AjiXQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.336929"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.4ms Sent mail to user@example.com (1.7ms) Date: Mon, 28 Sep 2015 13:37:48 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b60c531cd_1059c3ff550c601f8158ee@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.344496"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.344496"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1394 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.348062"], ["state", "pending"], ["target_id", 1394], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.348062"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1668]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1394]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1394 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1394 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.356616"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.356616"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1395 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.359659"], ["state", "pending"], ["target_id", 1395], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.359659"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1669]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1395]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1395 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1395]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1395 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1669 [["sent_time", "2015-09-28 03:37:48.364542"], ["state", "sent"], ["updated_at", "2015-09-28 03:37:48.366991"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1395 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.373113"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.373113"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1396 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.376962"], ["state", "pending"], ["target_id", 1396], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.376962"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1396 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.381787"], ["state", "pending"], ["target_id", 1396], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.381787"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1671]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1396]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1396 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) SAVEPOINT active_record_1 User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1396]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1396 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1671 [["sent_time", "2015-09-28 03:37:48.386402"], ["state", "sent"], ["updated_at", "2015-09-28 03:37:48.388829"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1396]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1396 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1670 [["sent_time", "2015-09-28 03:37:48.390519"], ["state", "sent"], ["updated_at", "2015-09-28 03:37:48.392957"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1396 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1396 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.400895"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.400895"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1397 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.404459"], ["state", "read"], ["target_id", 1397], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.404459"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1672]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1397]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1397 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.415767"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.415767"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1398 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1398 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.420358"], ["group_id", 2], ["state", "pending"], ["target_id", 1398], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.420358"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1673]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1398]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1398 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1398]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1398 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1398 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1673 [["sent_time", "2015-09-28 03:37:48.425307"], ["state", "sent"], ["updated_at", "2015-09-28 03:37:48.429943"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1398 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1398 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1673]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1398]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1398 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1398 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1398 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1398 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '1LhvG7CrbxL0fHzxhZWAHgxa5OAu2iU1Pk7cefN8sKDg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:48.441656"], ["target_id", 1398], ["target_type", "User"], ["token", "1LhvG7CrbxL0fHzxhZWAHgxa5OAu2iU1Pk7cefN8sKDg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.441656"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.5ms Sent mail to user@example.com (1.7ms) Date: Mon, 28 Sep 2015 13:37:48 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b60c6cb25_1059c3ff550c601f81591c@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.449001"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.449001"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.453809"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1399], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.453809"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1674 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.457952"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1674 [["sent_time", "2015-09-28 03:37:48.459129"], ["updated_at", "2015-09-28 03:37:48.461577"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1674]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.468634"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.468634"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1400 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1400 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.473129"], ["group_id", 1], ["state", "pending"], ["target_id", 1400], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.473129"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1400 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1675) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.479541"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.479541"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1401 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1401 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.483716"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1401], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.483716"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1401 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1401 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.488034"], ["group_id", 1], ["state", "pending"], ["target_id", 1401], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.488034"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1401 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1677) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.493833"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.493833"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1402 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1402 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.498465"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1402], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.498465"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1402 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1402 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.504279"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1402], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.504279"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1402 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1402 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.508502"], ["group_id", 1], ["state", "pending"], ["target_id", 1402], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.508502"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1402 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1680) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.514060"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.514060"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1403 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1403 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.518270"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 1403], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.518270"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1403 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1403 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.538036"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 1403], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.538036"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1403 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1403 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.542734"], ["group_id", 1], ["state", "pending"], ["target_id", 1403], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.542734"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1403 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1683) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.549563"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.549563"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1404 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1404 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.554673"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1404], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.554673"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1404 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1404 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.559591"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1404], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.559591"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1404 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1404 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.564373"], ["group_id", 1], ["state", "pending"], ["target_id", 1404], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.564373"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1404 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1686) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.571182"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.571182"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1405 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1405 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 17:37:48.572391"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1405], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.576579"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1405 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:37:48.579448') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1405 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:37:48.579448') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1405 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1405 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:37:48.586372"], ["group_id", 1], ["parent_id", 1687], ["state", "pending"], ["target_id", 1405], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.586372"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.590932"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.590932"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1406 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1406 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:37:48.592421"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1406], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.596423"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1406 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:37:48.598600')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1406 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1406 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.603231"], ["group_id", 1], ["state", "pending"], ["target_id", 1406], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.603231"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.607426"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.607426"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1407 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1407 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:37:48.608537"], ["group_id", 1], ["state", "pending"], ["target_id", 1407], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.612087"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1407 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:37:48.614782')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1407 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1407 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.620277"], ["group_id", 1], ["state", "pending"], ["target_id", 1407], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.620277"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.625079"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.625079"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1408 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1408 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.631277"], ["group_id", 1], ["state", "pending"], ["target_id", 1408], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.631277"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1408 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1693) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1408 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1693) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.638641"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.638641"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1409 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1409 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.643406"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1409], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.643406"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1409 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1409 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1694 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.648212"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1409 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1409 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1694 [["sent_time", "2015-09-28 03:37:48.649557"], ["updated_at", "2015-09-28 03:37:48.652474"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1409 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1409 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.657133"], ["group_id", 1], ["state", "pending"], ["target_id", 1409], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.657133"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1409 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1695) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1409 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1695) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.665263"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.665263"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.670324"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1410], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.670324"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1696 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.674762"]]  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1696 [["sent_time", "2015-09-28 03:37:48.676342"], ["updated_at", "2015-09-28 03:37:48.680095"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.684967"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1410], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.684967"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1697 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.689444"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1697 [["sent_time", "2015-09-28 03:37:48.690774"], ["updated_at", "2015-09-28 03:37:48.693587"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.698628"], ["group_id", 1], ["state", "pending"], ["target_id", 1410], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.698628"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1410 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1698) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1410 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1698) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.707799"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.707799"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.712793"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.712793"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1699 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.717476"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1699 [["sent_time", "2015-09-28 03:37:48.718804"], ["updated_at", "2015-09-28 03:37:48.721623"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.726370"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.726370"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1700 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.731234"]]  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1700 [["sent_time", "2015-09-28 03:37:48.732723"], ["updated_at", "2015-09-28 03:37:48.736882"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.741641"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.741641"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1701 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.745942"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1701 [["sent_time", "2015-09-28 03:37:48.747193"], ["updated_at", "2015-09-28 03:37:48.749688"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.754033"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.754033"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1702 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.757888"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1702 [["sent_time", "2015-09-28 03:37:48.759013"], ["updated_at", "2015-09-28 03:37:48.761344"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.765693"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.765693"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1703 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.769808"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1703 [["sent_time", "2015-09-28 03:37:48.771000"], ["updated_at", "2015-09-28 03:37:48.773494"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.777821"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.777821"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1704 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.782329"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1704 [["sent_time", "2015-09-28 03:37:48.783631"], ["updated_at", "2015-09-28 03:37:48.786265"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.790738"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.790738"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1705 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.794933"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1705 [["sent_time", "2015-09-28 03:37:48.796022"], ["updated_at", "2015-09-28 03:37:48.798678"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.802963"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.802963"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1706 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.806866"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1706 [["sent_time", "2015-09-28 03:37:48.807955"], ["updated_at", "2015-09-28 03:37:48.810366"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.814663"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.814663"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1707 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.818513"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1707 [["sent_time", "2015-09-28 03:37:48.819704"], ["updated_at", "2015-09-28 03:37:48.822377"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.826751"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.826751"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1708 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.830798"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1708 [["sent_time", "2015-09-28 03:37:48.832052"], ["updated_at", "2015-09-28 03:37:48.834732"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.839363"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.839363"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1709 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.843521"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1709 [["sent_time", "2015-09-28 03:37:48.844706"], ["updated_at", "2015-09-28 03:37:48.847125"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.851764"], ["group_id", 1], ["state", "pending"], ["target_id", 1411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.851764"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1411 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1710) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1411 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1710) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.859896"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.859896"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.864642"], ["group_id", 1], ["state", "pending"], ["target_id", 1412], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.864642"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1412 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1711)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1711 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.876065"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.880931"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.880931"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.885562"], ["group_id", 1], ["state", "pending"], ["target_id", 1413], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.885562"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1413 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1712)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1712 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.893718"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.898413"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.898413"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1414 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1414 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.902837"], ["group_id", 1], ["state", "pending"], ["target_id", 1414], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.902837"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1414 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1414 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1414 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1713)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1414 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1414 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1713 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.911948"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1713]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.917968"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.917968"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.922280"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1415], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.922280"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:48.922280"], ["group_id", 1], ["state", "pending"], ["target_id", 1415], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.926773"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1415 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1715)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1715 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:37:48.936288"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.941331"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.941331"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1416 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1416 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.945604"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1416], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.945604"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1416 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:37:48.948328') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1416 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:37:48.948328') ORDER BY created_at DESC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1416 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1416 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:39:48.945604"], ["group_id", 1], ["parent_id", 1716], ["state", "pending"], ["target_id", 1416], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.953419"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1717]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.958464"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.958464"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1417 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1417 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.964216"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1417], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.964216"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1417 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1417 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.968435"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1417], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.968435"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1417 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1417 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.972582"], ["group_id", 1], ["state", "pending"], ["target_id", 1417], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.972582"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1417 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1417 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1417 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1720)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:48.980444"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:48.980444"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.984952"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1418], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.984952"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.989082"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1418], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.989082"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:48.993151"], ["group_id", 1], ["state", "pending"], ["target_id", 1418], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:48.993151"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1418 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1723) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1723]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.002458"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.002458"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1419 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.007529"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.007529"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1420 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1420 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.014797"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.014797"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1421 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.020572"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.020572"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1422 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.023585"], ["state", "pending"], ["target_id", 1422], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.023585"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1422) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:49.026603"], ["target_id", 1422], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.026603"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1422 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.031434"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.031434"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1423 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.034883"], ["state", "pending"], ["target_id", 1423], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.034883"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1423 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.039866"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.039866"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1424 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.042985"], ["state", "pending"], ["target_id", 1424], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.042985"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1424) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:49.045999"], ["target_id", 1424], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:37:49.045999"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1424 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1424 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.051793"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.051793"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1425 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.055067"], ["state", "pending"], ["target_id", 1425], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.055067"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1425 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1425 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.067474"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.067474"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1426 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.071770"], ["state", "pending"], ["target_id", 1426], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.071770"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1426) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.075067"], ["group_id", 1], ["target_id", 1426], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.075067"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1426 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1426 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.082409"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.082409"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1427 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.085821"], ["state", "pending"], ["target_id", 1427], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.085821"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1427) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:49.088646"], ["target_id", 1427], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.088646"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1427 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1427 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.095495"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.095495"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1428 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.099226"], ["state", "pending"], ["target_id", 1428], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.099226"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1428 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1428 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1730 [["group_id", 1], ["updated_at", "2015-09-28 03:37:49.103508"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1428 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1428 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.111397"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.111397"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1429 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.114927"], ["state", "pending"], ["target_id", 1429], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.114927"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1731]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1429]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1429 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1429 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.123748"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.123748"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1430 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.127123"], ["state", "pending"], ["target_id", 1430], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.127123"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1430) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:49.130134"], ["target_id", 1430], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:37:49.130134"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1732]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1430]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1430 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1430 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.138042"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.138042"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1431 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.141168"], ["state", "pending"], ["target_id", 1431], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.141168"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1431) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.143936"], ["group_id", 1], ["target_id", 1431], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.143936"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1431 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1733]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1431]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1431 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.153475"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.153475"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1432 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.156768"], ["state", "pending"], ["target_id", 1432], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.156768"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1432 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1432 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.163654"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.163654"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1433 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.167240"], ["state", "pending"], ["target_id", 1433], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.167240"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1433) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:49.170242"], ["target_id", 1433], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:37:49.170242"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1433 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1433 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.176246"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.176246"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1434 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.179934"], ["state", "pending"], ["target_id", 1434], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.179934"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1434) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.183036"], ["group_id", 1], ["target_id", 1434], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.183036"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1434 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1434 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.190275"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.190275"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1435 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.193843"], ["state", "pending"], ["target_id", 1435], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.193843"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1435 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'gs1RqRup8hSZ2bDuqXVuEgvIj9_JuX1NOQed_p0q6RvA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.197567"], ["target_id", 1435], ["target_type", "User"], ["token", "gs1RqRup8hSZ2bDuqXVuEgvIj9_JuX1NOQed_p0q6RvA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.197567"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.203034"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.203034"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.206498"], ["state", "pending"], ["target_id", 1436], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.206498"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1436 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '2Ca09aYbDUcMJ8S-J98hIQGJv4pD7tAA-5YpJFPSIxDA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.209886"], ["target_id", 1436], ["target_type", "User"], ["token", "2Ca09aYbDUcMJ8S-J98hIQGJv4pD7tAA-5YpJFPSIxDA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.209886"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1436 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.216823"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.216823"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.220198"], ["state", "pending"], ["target_id", 1437], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.220198"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1437 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'o7nlzuP0uskfKGDZ4hpMtw58BoPKm41SWilhRLiPDMpw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.223616"], ["target_id", 1437], ["target_type", "User"], ["token", "o7nlzuP0uskfKGDZ4hpMtw58BoPKm41SWilhRLiPDMpw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.223616"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 177 [["active", "f"], ["updated_at", "2015-09-28 03:37:49.226414"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1437 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'YEyNtZgpnGtGHk_O1oPNngnNsZqdEGyESpYAzMTlRF3g' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.229591"], ["target_id", 1437], ["target_type", "User"], ["token", "YEyNtZgpnGtGHk_O1oPNngnNsZqdEGyESpYAzMTlRF3g"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.229591"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.234299"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.234299"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1438 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1438) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:49.238122"], ["target_id", 1438], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.238122"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.241421"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.241421"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1439 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1439) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:49.245084"], ["target_id", 1439], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.245084"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1439 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.250968"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.250968"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1440) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:49.254343"], ["target_id", 1440], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.254343"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1440 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 299]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.262565"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.262565"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1441) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:49.265514"], ["target_id", 1441], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-28 03:37:49.265514"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1441 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.270632"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.270632"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1442) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.273521"], ["group_id", 1], ["target_id", 1442], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.273521"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (1.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1442 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.6ms) SAVEPOINT active_record_1 SQL (2.1ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 301]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.286830"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.286830"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.6ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1443) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.292503"], ["group_id", 1], ["target_id", 1443], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.292503"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1443 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.299013"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.299013"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1444) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:49.301712"], ["target_id", 1444], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.301712"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1444 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.306366"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.306366"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1445) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:49.309003"], ["target_id", 1445], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.309003"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1445 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.315822"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.315822"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1446) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:37:49.318736"], ["target_id", 1446], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.318736"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1446) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1446 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1446 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 305]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1446 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.329401"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.329401"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1447 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.334264"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.334264"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'l7hAG5iG08Ddx6m2vmoAaQT7PLEzaHHApD-9qo2lLX4Q' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.335949"], ["target_id", 1448], ["target_type", "User"], ["token", "l7hAG5iG08Ddx6m2vmoAaQT7PLEzaHHApD-9qo2lLX4Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.335949"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'l7hAG5iG08Ddx6m2vmoAaQT7PLEzaHHApD-9qo2lLX4Q' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.341621"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.341621"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'LbieLOaDPjZTcHvBjO8vswbNFS5UR--0sNyvahIQb2pQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.343594"], ["target_id", 1449], ["target_type", "User"], ["token", "LbieLOaDPjZTcHvBjO8vswbNFS5UR--0sNyvahIQb2pQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.343594"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 180 [["active", "f"], ["updated_at", "2015-09-28 03:37:49.347259"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'LbieLOaDPjZTcHvBjO8vswbNFS5UR--0sNyvahIQb2pQ' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.351119"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.351119"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'rez23qgZ1xupA4pvzCj2HAz-TRcsF4-wlAKvBDOs0tYQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.352910"], ["target_id", 1450], ["target_type", "User"], ["token", "rez23qgZ1xupA4pvzCj2HAz-TRcsF4-wlAKvBDOs0tYQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.352910"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 181 [["active", "f"], ["updated_at", "2015-09-28 03:37:49.356107"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.358914"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:37:49.358914"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'OaV2b6s3UPheYTsizXbRMwh4ykTEF1fWybxrOORuSxpg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:37:49.361706"], ["target_id", 1451], ["target_type", "User"], ["token", "OaV2b6s3UPheYTsizXbRMwh4ykTEF1fWybxrOORuSxpg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.361706"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.367716"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-28 03:37:49.367716"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1452 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:49.370617"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1452], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.370617"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:37:49.375224"], ["email", "2@notifyuser.com"], ["updated_at", "2015-09-28 03:37:49.375224"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1453 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:37:49.378339"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1453], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:37:49.378339"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:06.566670"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:06.566670"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.2ms) Completed 200 OK in 21ms (Views: 15.6ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:06.604847"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:06.604847"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1455 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.633406"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1455], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.633406"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1455 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (1.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1455 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 15ms  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:06.657899"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:06.657899"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1456 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.663470"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1456], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.663470"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1456 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1456 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:06.676571"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:06.676571"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1457 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.682010"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1457], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.682010"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1457 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.685208"], ["parent_id", 1], ["state", "pending"], ["target_id", 1457], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.685208"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1457 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1457 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:06.700202"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:06.700202"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1458 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.705793"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1458], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.705793"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1458 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.709214"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1458], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.709214"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1458 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.712621"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1458], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.712621"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1458 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 155ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:06.879373"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:06.879373"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1459 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.887577"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1459], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.887577"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1459 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.896327"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1459], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.896327"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1459 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.900683"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1459], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.900683"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1749"} NotifyUser::BaseNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1459 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1749') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1459]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1459 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1749 [["state", "read"], ["updated_at", "2015-09-28 03:39:06.915644"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 16ms (Views: 1.9ms | ActiveRecord: 2.0ms) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 1749 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:06.929111"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:06.929111"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1460 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.935294"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1460], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.935294"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1460 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.939654"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1460], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.939654"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1460 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.943578"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1460], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.943578"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1752"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1460 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1752') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1460]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1460 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1752 [["state", "read"], ["updated_at", "2015-09-28 03:39:06.953144"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.3ms | ActiveRecord: 1.6ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1752"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1460 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1752') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.2ms | ActiveRecord: 2.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:06.963772"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:06.963772"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1461 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.970320"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1461], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.970320"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1461 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.974153"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1461], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.974153"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1461 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:06.977804"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1461], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:06.977804"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1461 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1461 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 4ms (Views: 0.8ms | ActiveRecord: 1.0ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1461 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:06.991598"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:06.991598"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 3ms (Views: 1.9ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.008798"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.008798"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 3ms (Views: 1.9ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.024533"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.024533"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1464 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:07.031884"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1464], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.031884"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["1758"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1464 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1758')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1464 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1758')) Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.048553"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.048553"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1465 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:07.057192"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1465], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.057192"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["1759"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1465 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1759')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1465 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1759')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.074303"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.074303"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1466 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:07.082322"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1466], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.082322"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1466 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1466 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1466) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:07.104992"], ["target_id", 1466], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.104992"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1466 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 22ms (Views: 2.2ms | ActiveRecord: 2.0ms) NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1466 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.118932"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.118932"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1467 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:07.125366"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1467], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.125366"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1467 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1467 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1467 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 17ms (Views: 13.0ms | ActiveRecord: 0.7ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1467 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.154700"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.154700"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1468 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:07.161157"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1468], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.161157"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1468 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1468) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:07.169922"], ["target_id", 1468], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.169922"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1468 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 8ms (ActiveRecord: 1.7ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.180559"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.180559"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1469 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:07.187446"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1469], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.187446"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1469) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:07.190975"], ["target_id", 1469], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.190975"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1469 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 308]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 4ms (ActiveRecord: 1.0ms) NotifyUser::Unsubscribe Load (0.2ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.204495"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.204495"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1470 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:07.210692"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1470], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.210692"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1470 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'aPvGykomnGIVmN31Rppq8wzKTFGva_czzHeO7Nabwa4w' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.220320"], ["target_id", 1470], ["target_type", "User"], ["token", "aPvGykomnGIVmN31Rppq8wzKTFGva_czzHeO7Nabwa4w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.220320"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"aPvGykomnGIVmN31Rppq8wzKTFGva_czzHeO7Nabwa4w"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'aPvGykomnGIVmN31Rppq8wzKTFGva_czzHeO7Nabwa4w' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'aPvGykomnGIVmN31Rppq8wzKTFGva_czzHeO7Nabwa4w' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1470]]  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1470) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:07.229475"], ["target_id", 1470], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.229475"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 183 [["active", "f"], ["updated_at", "2015-09-28 03:39:07.231129"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.3ms | ActiveRecord: 2.3ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.236614"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.236614"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1471 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.240082"], ["state", "pending"], ["target_id", 1471], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.240082"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (1.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1471 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1471 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.251796"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.251796"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1472 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.255145"], ["state", "pending"], ["target_id", 1472], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.255145"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1472 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1472 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.264243"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.264243"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1473 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.268008"], ["state", "pending"], ["target_id", 1473], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.268008"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1473 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.275127"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.275127"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1474 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.278537"], ["state", "pending"], ["target_id", 1474], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.278537"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1474 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 23.4ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.5ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.5ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.549002"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.549002"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.552434"], ["state", "pending"], ["target_id", 1475], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.552434"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1475 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.558900"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.558900"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1476 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.562654"], ["state", "pending"], ["target_id", 1476], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.562654"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1476 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.569972"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.569972"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1477 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.573638"], ["state", "pending"], ["target_id", 1477], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.573638"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1477 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.581958"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.581958"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1478 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.585112"], ["state", "pending"], ["target_id", 1478], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.585112"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1478 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.591240"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.591240"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1479 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.594473"], ["state", "pending"], ["target_id", 1479], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.594473"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1479 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.600259"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.600259"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1480 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.604006"], ["state", "pending"], ["target_id", 1480], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.604006"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.608203"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.608203"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1481 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.611576"], ["state", "pending"], ["target_id", 1481], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.611576"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.616523"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.616523"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1482 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.620006"], ["state", "pending"], ["target_id", 1482], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.620006"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1482 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1776 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:39:07.623146"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.629578"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.629578"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1483 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.633085"], ["state", "pending"], ["target_id", 1483], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.633085"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1483 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1777 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:39:07.636167"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.641406"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.641406"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1484 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.644571"], ["state", "pending"], ["target_id", 1484], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.644571"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1484 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1778 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:39:07.647792"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.653945"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.653945"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1485 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.657288"], ["state", "pending"], ["target_id", 1485], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.657288"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1485 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1779 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:39:07.660213"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.665508"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.665508"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1486 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.668778"], ["state", "pending"], ["target_id", 1486], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.668778"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1486 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.674950"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.674950"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1487 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.678148"], ["state", "pending"], ["target_id", 1487], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.678148"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1487 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1487 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1781 [["state", "sent"], ["updated_at", "2015-09-28 03:39:07.682829"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1487 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1781 [["sent_time", "2015-09-28 03:39:07.684029"], ["updated_at", "2015-09-28 03:39:07.685426"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.690509"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.690509"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1488 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.694353"], ["state", "pending"], ["target_id", 1488], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.694353"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1488 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1488 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1782)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1488 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1782 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:07.701948"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1782]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1488]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1488 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1488]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1488 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1782 [["sent_time", "2015-09-28 03:39:07.708520"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:07.711343"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1488 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1782]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1488]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1488 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1488 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1488 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '4omdFMc0lM7XDmf86mLFdwW8na3To9tCOyrQKA4A2JRQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.721987"], ["target_id", 1488], ["target_type", "User"], ["token", "4omdFMc0lM7XDmf86mLFdwW8na3To9tCOyrQKA4A2JRQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.721987"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.6ms Sent mail to user@example.com (4.2ms) Date: Mon, 28 Sep 2015 13:39:07 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b65bb17f2_107f03fc625808204279c9@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.732652"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.732652"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1489 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.737447"], ["state", "pending_as_aggregation_parent"], ["target_id", 1489], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.737447"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1489 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.740988"], ["state", "pending"], ["target_id", 1489], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.740988"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1489 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1489 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1784)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.748104"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.748104"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1490 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.751328"], ["state", "pending"], ["target_id", 1490], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.751328"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1490 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1490 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1785 [["state", "sent"], ["updated_at", "2015-09-28 03:39:07.755432"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1490 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1785 [["sent_time", "2015-09-28 03:39:07.756579"], ["updated_at", "2015-09-28 03:39:07.758017"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1785]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1490]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1490 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1490 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1490 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'wX33MBxKFoQbTrUJUEjfTAJrcNBvo2vY6bhzgX1xvZSw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.766881"], ["target_id", 1490], ["target_type", "User"], ["token", "wX33MBxKFoQbTrUJUEjfTAJrcNBvo2vY6bhzgX1xvZSw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.766881"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.7ms Sent mail to user@example.com (1.9ms) Date: Mon, 28 Sep 2015 13:39:07 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b65bbc6b3_107f03fc625808204280b1@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.775872"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.775872"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1491 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.779274"], ["state", "pending"], ["target_id", 1491], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.779274"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1491 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1786 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 03:39:07.782470"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.787714"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.787714"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1492 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.791216"], ["state", "pending"], ["target_id", 1492], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.791216"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1492) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:07.794189"], ["target_id", 1492], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:39:07.794189"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1787]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1492]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1492 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1492 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.802782"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.802782"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1493 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.806080"], ["state", "pending"], ["target_id", 1493], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.806080"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1788]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1493]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1493 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1493 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.813948"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.813948"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1494 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.817108"], ["state", "pending"], ["target_id", 1494], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.817108"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1494 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1494 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1789 [["state", "sent"], ["updated_at", "2015-09-28 03:39:07.822257"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1494 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1789 [["sent_time", "2015-09-28 03:39:07.823591"], ["updated_at", "2015-09-28 03:39:07.825081"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1789]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1494]]  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1494 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1494 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1494 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'zaf2OJpGAUDzbUJ6HTZecA093HFj4Gryovf9NN7rWCQw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.834930"], ["target_id", 1494], ["target_type", "User"], ["token", "zaf2OJpGAUDzbUJ6HTZecA093HFj4Gryovf9NN7rWCQw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.834930"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.9ms Sent mail to user@example.com (1.9ms) Date: Mon, 28 Sep 2015 13:39:07 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b65bccbe4_107f03fc625808204281b@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.843160"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.843160"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1495 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.846434"], ["state", "pending"], ["target_id", 1495], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.846434"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1790]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1495]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1495 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1495 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.855050"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.855050"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1496 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.858732"], ["state", "pending"], ["target_id", 1496], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.858732"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1791]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1496]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1496 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1496]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1496 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (2.0ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1791 [["sent_time", "2015-09-28 03:39:07.863618"], ["state", "sent"], ["updated_at", "2015-09-28 03:39:07.866075"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1496 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.874308"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.874308"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1497 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.877958"], ["state", "pending"], ["target_id", 1497], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.877958"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1497 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.882418"], ["state", "pending"], ["target_id", 1497], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.882418"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1793]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1497]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1497 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1497]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1497 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1793 [["sent_time", "2015-09-28 03:39:07.887000"], ["state", "sent"], ["updated_at", "2015-09-28 03:39:07.889620"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1497]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1497 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1792 [["sent_time", "2015-09-28 03:39:07.891511"], ["state", "sent"], ["updated_at", "2015-09-28 03:39:07.893991"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1497 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1497 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.901880"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.901880"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1498 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.905054"], ["state", "read"], ["target_id", 1498], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.905054"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1794]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1498]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1498 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.912430"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.912430"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1499 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1499 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:07.917144"], ["group_id", 2], ["state", "pending"], ["target_id", 1499], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.917144"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1795]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1499]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1499 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.3ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1499]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1499 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1499 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1795 [["sent_time", "2015-09-28 03:39:07.922259"], ["state", "sent"], ["updated_at", "2015-09-28 03:39:07.926569"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1499 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1499 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1795]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1499]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1499 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1499 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1499 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1499 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'xaEE7JSs56buIHMkZW2rBgrGDP8U8YPqgEkZFn3JdqAg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:07.939881"], ["target_id", 1499], ["target_type", "User"], ["token", "xaEE7JSs56buIHMkZW2rBgrGDP8U8YPqgEkZFn3JdqAg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.939881"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.8ms Sent mail to user@example.com (1.6ms) Date: Mon, 28 Sep 2015 13:39:07 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b65be644d_107f03fc62580820428250@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.947901"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.947901"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1500 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1500 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:07.952378"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1500], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.952378"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1500 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1500 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1796 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:07.956940"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1500 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1500 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1796 [["sent_time", "2015-09-28 03:39:07.958152"], ["updated_at", "2015-09-28 03:39:07.961006"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1796]]  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.968508"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.968508"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1501 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1501 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:07.973296"], ["group_id", 1], ["state", "pending"], ["target_id", 1501], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.973296"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1501 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1797) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.979193"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.979193"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1502 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1502 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:07.984836"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1502], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.984836"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1502 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1502 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:07.989581"], ["group_id", 1], ["state", "pending"], ["target_id", 1502], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.989581"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1502 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1799) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:07.995192"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:07.995192"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1503 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1503 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:07.999573"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1503], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:07.999573"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1503 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1503 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.003900"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1503], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.003900"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1503 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1503 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.008111"], ["group_id", 1], ["state", "pending"], ["target_id", 1503], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.008111"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1503 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1802) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.014131"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.014131"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1504 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1504 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.028139"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 1504], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.028139"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1504 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1504 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.033517"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 1504], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.033517"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1504 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1504 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.043281"], ["group_id", 1], ["state", "pending"], ["target_id", 1504], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.043281"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1504 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1805) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.056312"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.056312"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1505 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1505 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.073585"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1505], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.073585"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (2.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1505 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1505 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.083311"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1505], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.083311"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1505 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1505 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.091430"], ["group_id", 1], ["state", "pending"], ["target_id", 1505], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.091430"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1505 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1808) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.103222"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.103222"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1506 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1506 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 17:39:08.105422"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1506], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.112600"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1506 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:39:08.116623') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1506 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:39:08.116623') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1506 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1506 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:39:08.122883"], ["group_id", 1], ["parent_id", 1809], ["state", "pending"], ["target_id", 1506], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.122883"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.128010"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.128010"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1507 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1507 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:39:08.129145"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1507], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.133058"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1507 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:39:08.135415')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1507 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1507 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.139791"], ["group_id", 1], ["state", "pending"], ["target_id", 1507], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.139791"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.144948"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.144948"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1508 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1508 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:39:08.147146"], ["group_id", 1], ["state", "pending"], ["target_id", 1508], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.151603"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1508 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:39:08.154358')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1508 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1508 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.159423"], ["group_id", 1], ["state", "pending"], ["target_id", 1508], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.159423"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.163812"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.163812"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1509 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1509 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.168565"], ["group_id", 1], ["state", "pending"], ["target_id", 1509], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.168565"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1509 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1815) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1509 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1815) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.176710"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.176710"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.181642"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1510], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.181642"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1816 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.187292"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1816 [["sent_time", "2015-09-28 03:39:08.188891"], ["updated_at", "2015-09-28 03:39:08.191695"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.196925"], ["group_id", 1], ["state", "pending"], ["target_id", 1510], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.196925"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1510 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1817) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1510 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1817) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.206846"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.206846"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.211984"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1511], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.211984"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1818 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.216478"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1818 [["sent_time", "2015-09-28 03:39:08.217687"], ["updated_at", "2015-09-28 03:39:08.220336"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.225044"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1511], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.225044"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1819 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.229497"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1819 [["sent_time", "2015-09-28 03:39:08.230722"], ["updated_at", "2015-09-28 03:39:08.233644"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.238568"], ["group_id", 1], ["state", "pending"], ["target_id", 1511], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.238568"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1511 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1820) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1511 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1820) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.247742"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.247742"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.253133"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1512], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.253133"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1821 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.258010"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1821 [["sent_time", "2015-09-28 03:39:08.259293"], ["updated_at", "2015-09-28 03:39:08.262326"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.267183"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1512], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.267183"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1822 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.271463"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1822 [["sent_time", "2015-09-28 03:39:08.272670"], ["updated_at", "2015-09-28 03:39:08.275247"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.279748"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1512], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.279748"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1823 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.285174"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1823 [["sent_time", "2015-09-28 03:39:08.286786"], ["updated_at", "2015-09-28 03:39:08.289788"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.294425"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1512], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.294425"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1824 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.298769"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1824 [["sent_time", "2015-09-28 03:39:08.299874"], ["updated_at", "2015-09-28 03:39:08.302245"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.306485"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1512], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.306485"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1825 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.310504"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1825 [["sent_time", "2015-09-28 03:39:08.311634"], ["updated_at", "2015-09-28 03:39:08.314231"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.318881"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1512], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.318881"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1826 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.323046"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1826 [["sent_time", "2015-09-28 03:39:08.324230"], ["updated_at", "2015-09-28 03:39:08.326752"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.331136"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1512], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.331136"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1827 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.335446"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1827 [["sent_time", "2015-09-28 03:39:08.336832"], ["updated_at", "2015-09-28 03:39:08.339460"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.344619"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1512], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.344619"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1828 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.348992"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1828 [["sent_time", "2015-09-28 03:39:08.350143"], ["updated_at", "2015-09-28 03:39:08.352618"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.357831"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1512], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.357831"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1829 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.362390"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1829 [["sent_time", "2015-09-28 03:39:08.363723"], ["updated_at", "2015-09-28 03:39:08.366339"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.371136"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1512], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.371136"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1830 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.375509"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1830 [["sent_time", "2015-09-28 03:39:08.376848"], ["updated_at", "2015-09-28 03:39:08.379610"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.384137"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1512], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.384137"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1831 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.388525"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1831 [["sent_time", "2015-09-28 03:39:08.389740"], ["updated_at", "2015-09-28 03:39:08.392372"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.397174"], ["group_id", 1], ["state", "pending"], ["target_id", 1512], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.397174"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1512 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1832) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1512 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1832) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.405994"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.405994"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1513 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1513 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.411185"], ["group_id", 1], ["state", "pending"], ["target_id", 1513], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.411185"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1513 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1513 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1513 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1833)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1513 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1513 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1833 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.422715"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.427995"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.427995"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.432380"], ["group_id", 1], ["state", "pending"], ["target_id", 1514], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.432380"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1514 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1834)  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1834 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.441519"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.446726"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.446726"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1515 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1515 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.452949"], ["group_id", 1], ["state", "pending"], ["target_id", 1515], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.452949"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1515 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1515 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1515 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1835)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1515 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1515 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1835 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.461800"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1835]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.468070"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.468070"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.472771"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1516], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.472771"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:41:08.472771"], ["group_id", 1], ["state", "pending"], ["target_id", 1516], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.477266"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1516 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1837)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1837 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:39:08.485724"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.490281"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.490281"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1517 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1517 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.494944"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1517], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.494944"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1517 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:39:08.497393') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1517 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:39:08.497393') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1517 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1517 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:41:08.494944"], ["group_id", 1], ["parent_id", 1838], ["state", "pending"], ["target_id", 1517], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.503391"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1839]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.508556"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.508556"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1518 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1518 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.513377"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1518], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.513377"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1518 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1518 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.518611"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1518], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.518611"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1518 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1518 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.6ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.523078"], ["group_id", 1], ["state", "pending"], ["target_id", 1518], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.523078"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1518 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1518 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1518 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1842)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.534793"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.534793"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.539646"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1519], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.539646"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.544170"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1519], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.544170"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.549628"], ["group_id", 1], ["state", "pending"], ["target_id", 1519], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.549628"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1519 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1845) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1845]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.559448"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.559448"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1520 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.565593"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.565593"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1521 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1521 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.572773"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.572773"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1522 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.579313"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.579313"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1523 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.582676"], ["state", "pending"], ["target_id", 1523], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.582676"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1523) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:08.585946"], ["target_id", 1523], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.585946"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1523 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.590797"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.590797"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1524 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.594069"], ["state", "pending"], ["target_id", 1524], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.594069"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1524 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.599817"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.599817"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.603314"], ["state", "pending"], ["target_id", 1525], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.603314"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1525) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:08.606205"], ["target_id", 1525], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:39:08.606205"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.612366"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.612366"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1526 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.615765"], ["state", "pending"], ["target_id", 1526], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.615765"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1526 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1526 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.621804"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.621804"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1527 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.625373"], ["state", "pending"], ["target_id", 1527], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.625373"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1527) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.628424"], ["group_id", 1], ["target_id", 1527], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.628424"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1527 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1527 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.635630"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.635630"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1528 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.638997"], ["state", "pending"], ["target_id", 1528], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.638997"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1528) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:08.641897"], ["target_id", 1528], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.641897"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1528 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1528 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.650389"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.650389"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1529 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.653983"], ["state", "pending"], ["target_id", 1529], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.653983"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1529 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1529 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1852 [["group_id", 1], ["updated_at", "2015-09-28 03:39:08.658528"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1529 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1529 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.665273"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.665273"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.668343"], ["state", "pending"], ["target_id", 1530], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.668343"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1853]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1530]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.676425"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.676425"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.679759"], ["state", "pending"], ["target_id", 1531], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.679759"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1531) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:08.683011"], ["target_id", 1531], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:39:08.683011"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1854]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1531]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.691797"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.691797"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.695029"], ["state", "pending"], ["target_id", 1532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.695029"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1532) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.697915"], ["group_id", 1], ["target_id", 1532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.697915"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1855]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1532]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.707715"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.707715"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1533 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.710990"], ["state", "pending"], ["target_id", 1533], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.710990"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1533 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1533 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.717389"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.717389"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1534 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.720709"], ["state", "pending"], ["target_id", 1534], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.720709"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1534) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:08.723644"], ["target_id", 1534], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:39:08.723644"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1534 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1534 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.729930"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.729930"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1535 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.734091"], ["state", "pending"], ["target_id", 1535], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.734091"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1535) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.737443"], ["group_id", 1], ["target_id", 1535], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.737443"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1535 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1535 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.745321"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.745321"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.749346"], ["state", "pending"], ["target_id", 1536], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.749346"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1536 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '159WZdkJaxORkvF5VeepKQWQ0kqUgA7_c6mcHxc_ISRQ' LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.752723"], ["target_id", 1536], ["target_type", "User"], ["token", "159WZdkJaxORkvF5VeepKQWQ0kqUgA7_c6mcHxc_ISRQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.752723"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.757865"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.757865"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.761228"], ["state", "pending"], ["target_id", 1537], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.761228"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1537 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'qQahq2WSwe5azZ7xCUOlBwE1j2qCZMK0kMhSX_yAbeAg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.764850"], ["target_id", 1537], ["target_type", "User"], ["token", "qQahq2WSwe5azZ7xCUOlBwE1j2qCZMK0kMhSX_yAbeAg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.764850"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1537 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.771770"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.771770"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.775382"], ["state", "pending"], ["target_id", 1538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.775382"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1538 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.7ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'S41aM21ubxoaSc0xZfbS5A-5pKDM8rk2ANtis-JMk2pw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.778939"], ["target_id", 1538], ["target_type", "User"], ["token", "S41aM21ubxoaSc0xZfbS5A-5pKDM8rk2ANtis-JMk2pw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.778939"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 190 [["active", "f"], ["updated_at", "2015-09-28 03:39:08.782657"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1538 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'BCz2LmrQH3Ws4_xDILtEBw4Wdzh0Ffuy0mXVPsCPtesQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.785853"], ["target_id", 1538], ["target_type", "User"], ["token", "BCz2LmrQH3Ws4_xDILtEBw4Wdzh0Ffuy0mXVPsCPtesQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.785853"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.791094"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.791094"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1539 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1539) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:08.795431"], ["target_id", 1539], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.795431"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.798834"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.798834"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1540 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1540) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:08.802557"], ["target_id", 1540], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.802557"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1540 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.807904"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.807904"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1541) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:08.810879"], ["target_id", 1541], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.810879"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1541 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 321]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.818086"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.818086"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1542) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:08.822139"], ["target_id", 1542], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-28 03:39:08.822139"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1542 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.827429"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.827429"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1543) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.830161"], ["group_id", 1], ["target_id", 1543], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.830161"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1543 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 323]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.836216"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.836216"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1544) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.838925"], ["group_id", 1], ["target_id", 1544], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.838925"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1544 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.844827"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.844827"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1545) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:08.847584"], ["target_id", 1545], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.847584"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1545 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.852314"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.852314"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1546) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:08.855509"], ["target_id", 1546], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.855509"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1546 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.861072"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.861072"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.7ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1547) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:39:08.864756"], ["target_id", 1547], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.864756"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1547) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1547 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1547 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 327]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1547 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.875755"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.875755"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1548 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.880580"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.880580"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'bGLIYaNzNBnyB6N6_PHAvw1SXb7t_xXNcCLRObWCgWiw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.882353"], ["target_id", 1549], ["target_type", "User"], ["token", "bGLIYaNzNBnyB6N6_PHAvw1SXb7t_xXNcCLRObWCgWiw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.882353"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'bGLIYaNzNBnyB6N6_PHAvw1SXb7t_xXNcCLRObWCgWiw' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.887999"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.887999"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'QGQD9OEmQjh0naUXqy54ow9eRPUVptOWBc4kWYE5zfzg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.890010"], ["target_id", 1550], ["target_type", "User"], ["token", "QGQD9OEmQjh0naUXqy54ow9eRPUVptOWBc4kWYE5zfzg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.890010"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 193 [["active", "f"], ["updated_at", "2015-09-28 03:39:08.893343"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'QGQD9OEmQjh0naUXqy54ow9eRPUVptOWBc4kWYE5zfzg' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.897000"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.897000"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'iI79GYDNWM3W90hhFWd_yw5jurRKNQ8OFV6aAQykJKyg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.899085"], ["target_id", 1551], ["target_type", "User"], ["token", "iI79GYDNWM3W90hhFWd_yw5jurRKNQ8OFV6aAQykJKyg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.899085"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 194 [["active", "f"], ["updated_at", "2015-09-28 03:39:08.902377"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.905074"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:39:08.905074"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '8s7S-z9xwu1kBMOeGeFcCg1aToKpIS_QMGHZoU_BBfrA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:39:08.907049"], ["target_id", 1552], ["target_type", "User"], ["token", "8s7S-z9xwu1kBMOeGeFcCg1aToKpIS_QMGHZoU_BBfrA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.907049"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.913171"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-28 03:39:08.913171"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1553 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.917128"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1553], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.917128"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:39:08.921901"], ["email", "2@notifyuser.com"], ["updated_at", "2015-09-28 03:39:08.921901"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1554 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:39:08.924990"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1554], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:39:08.924990"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:43.786243"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:43.786243"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.3ms) Completed 200 OK in 22ms (Views: 16.6ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:43.825984"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:43.825984"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1556 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:43.853989"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1556], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:43.853989"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1556 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1556 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 15ms  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:43.879751"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:43.879751"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1557 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.0ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:43.893999"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1557], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:43.893999"]]  (0.4ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1557 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1557 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:43.911241"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:43.911241"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1558 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:43.918519"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1558], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:43.918519"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1558 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:43.922332"], ["parent_id", 1], ["state", "pending"], ["target_id", 1558], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:43.922332"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1558 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1558 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:43.936856"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:43.936856"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1559 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:43.942523"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1559], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:43.942523"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1559 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:43.945833"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1559], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:43.945833"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1559 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:43.949054"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1559], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:43.949054"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1559 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 185ms  (0.3ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.147455"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.147455"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1560 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.8ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.156766"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1560], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.156766"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1560 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.174770"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1560], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.174770"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1560 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.183591"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1560], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.183591"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1871"} NotifyUser::BaseNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1560 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1871') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1560]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1560 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1871 [["state", "read"], ["updated_at", "2015-09-28 03:42:44.199554"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 16ms (Views: 1.7ms | ActiveRecord: 2.0ms) NotifyUser::BaseNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 1871 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.217822"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.217822"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1561 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.224387"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1561], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.224387"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1561 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.228753"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1561], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.228753"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1561 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.232657"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1561], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.232657"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1874"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1561 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1874') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1561]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1561 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1874 [["state", "read"], ["updated_at", "2015-09-28 03:42:44.242892"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.4ms | ActiveRecord: 1.4ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1874"} NotifyUser::BaseNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1561 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1874') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.2ms | ActiveRecord: 2.0ms)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.253801"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.253801"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1562 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.260071"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1562], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.260071"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1562 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.265045"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1562], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.265045"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1562 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.268867"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1562], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.268867"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1562 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1562 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 4ms (Views: 0.9ms | ActiveRecord: 1.0ms) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1562 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.284443"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.284443"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 4ms (Views: 2.3ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.304878"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.304878"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 4ms (Views: 2.1ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.321466"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.321466"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1565 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.328701"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1565], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.328701"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["1880"]} SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1565 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1880')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1565 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1880')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.347184"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.347184"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1566 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.355173"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1566], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.355173"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["1881"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1566 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1881')) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1566 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('1881')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.371955"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.371955"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1567 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.380776"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1567], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.380776"]]  (0.5ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.6ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1567 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1567 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1567) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:44.403494"], ["target_id", 1567], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.403494"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1567 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 22ms (Views: 2.0ms | ActiveRecord: 1.9ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1567 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.415947"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.415947"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1568 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.422208"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1568], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.422208"]]  (0.4ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.6ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1568 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1568 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1568 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 6ms (Views: 1.9ms | ActiveRecord: 0.7ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1568 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.450833"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.450833"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1569 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.456827"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1569], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.456827"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1569 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1569) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:44.465114"], ["target_id", 1569], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.465114"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1569 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 8ms (ActiveRecord: 1.7ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.473978"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.473978"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1570 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.480053"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1570], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.480053"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1570) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:44.483184"], ["target_id", 1570], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.483184"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1570 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 330]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 5ms (ActiveRecord: 1.0ms) NotifyUser::Unsubscribe Load (0.2ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.497509"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.497509"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1571 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:44.506187"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1571], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.506187"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.7ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1571 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'DdbN0K6PcfUD-G_rM8Rwbwa9Do5_iarDRjW9SBd0-azA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.517802"], ["target_id", 1571], ["target_type", "User"], ["token", "DdbN0K6PcfUD-G_rM8Rwbwa9Do5_iarDRjW9SBd0-azA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.517802"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"DdbN0K6PcfUD-G_rM8Rwbwa9Do5_iarDRjW9SBd0-azA"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'DdbN0K6PcfUD-G_rM8Rwbwa9Do5_iarDRjW9SBd0-azA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'DdbN0K6PcfUD-G_rM8Rwbwa9Do5_iarDRjW9SBd0-azA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1571]]  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1571) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:44.528454"], ["target_id", 1571], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.528454"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 196 [["active", "f"], ["updated_at", "2015-09-28 03:42:44.530291"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.3ms | ActiveRecord: 2.4ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.536465"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.536465"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1572 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.540310"], ["state", "pending"], ["target_id", 1572], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.540310"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1572 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1572 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.551252"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.551252"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1573 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.554982"], ["state", "pending"], ["target_id", 1573], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.554982"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1573 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1573 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.565987"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.565987"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1574 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.570439"], ["state", "pending"], ["target_id", 1574], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.570439"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1574 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.579949"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.579949"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1575 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.584022"], ["state", "pending"], ["target_id", 1575], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.584022"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1575 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 24.3ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.3ms NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.2ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.870634"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.870634"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1576 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.874359"], ["state", "pending"], ["target_id", 1576], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.874359"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1576 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.880554"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.880554"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1577 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.884948"], ["state", "pending"], ["target_id", 1577], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.884948"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1577 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.891183"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.891183"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1578 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.894716"], ["state", "pending"], ["target_id", 1578], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.894716"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1578 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.902773"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.902773"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1579 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.906104"], ["state", "pending"], ["target_id", 1579], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.906104"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1579 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.912760"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.912760"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1580 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.916315"], ["state", "pending"], ["target_id", 1580], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.916315"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1580 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.921919"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.921919"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1581 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.925568"], ["state", "pending"], ["target_id", 1581], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.925568"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.931146"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.931146"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1582 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.934856"], ["state", "pending"], ["target_id", 1582], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.934856"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.939227"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.939227"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1583 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.942777"], ["state", "pending"], ["target_id", 1583], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.942777"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1583 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1898 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:42:44.945752"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.950934"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.950934"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1584 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.954253"], ["state", "pending"], ["target_id", 1584], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.954253"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1584 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1899 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:42:44.957333"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.962361"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.962361"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1585 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.967566"], ["state", "pending"], ["target_id", 1585], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.967566"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1585 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1900 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:42:44.970920"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.976286"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.976286"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1586 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.979714"], ["state", "pending"], ["target_id", 1586], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.979714"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1586 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1901 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:42:44.982795"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:44.987929"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:44.987929"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1587 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:44.991876"], ["state", "pending"], ["target_id", 1587], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:44.991876"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1587 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.015510"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.015510"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1588 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.019560"], ["state", "pending"], ["target_id", 1588], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.019560"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1588 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.025848"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.025848"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1589 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.029464"], ["state", "pending"], ["target_id", 1589], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.029464"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.033883"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.033883"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1590 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.037199"], ["state", "pending"], ["target_id", 1590], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.037199"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1590 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1590 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1905)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1590 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1905 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.043609"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1905]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1590]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1590 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1590]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1590 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1905 [["sent_time", "2015-09-28 03:42:45.050533"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.053316"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1590 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1905]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1590]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1590 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1590 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1590 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '2Rj7GNOjXgtPznnJ8XEqnQDvVT9tDxum2VVXFXdVBKJw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.065032"], ["target_id", 1590], ["target_type", "User"], ["token", "2Rj7GNOjXgtPznnJ8XEqnQDvVT9tDxum2VVXFXdVBKJw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.065032"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.8ms Sent mail to user@example.com (4.2ms) Date: Mon, 28 Sep 2015 13:42:45 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b7351114a_10b393fd4cc86020027357@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.075731"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.075731"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1591 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.079975"], ["state", "pending_as_aggregation_parent"], ["target_id", 1591], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.079975"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1591 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.084247"], ["state", "pending"], ["target_id", 1591], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.084247"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1591 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1591 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 1907)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.091308"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.091308"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1592 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.094853"], ["state", "pending"], ["target_id", 1592], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.094853"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1592 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1592 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1908 [["state", "sent"], ["updated_at", "2015-09-28 03:42:45.099256"]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1592 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1908 [["sent_time", "2015-09-28 03:42:45.100981"], ["updated_at", "2015-09-28 03:42:45.102781"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1908]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1592]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1592 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1592 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1592 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Z2j6il4rZ_yj9tdzdtGJSA1ULY5KdpDAcS72kGD1GO1A' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.113952"], ["target_id", 1592], ["target_type", "User"], ["token", "Z2j6il4rZ_yj9tdzdtGJSA1ULY5KdpDAcS72kGD1GO1A"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.113952"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.8ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 13:42:45 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b7351cb7a_10b393fd4cc8602002749a@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.121776"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.121776"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1593 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.125195"], ["state", "pending"], ["target_id", 1593], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.125195"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1593 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1909 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 03:42:45.128406"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.132785"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.132785"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1594 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.136373"], ["state", "pending"], ["target_id", 1594], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.136373"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1594) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:45.139286"], ["target_id", 1594], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:42:45.139286"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1910]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1594]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1594 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1594 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.147239"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.147239"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1595 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.150409"], ["state", "pending"], ["target_id", 1595], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.150409"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1911]] User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1595]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1595 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1595 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.159785"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.159785"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1596 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.163817"], ["state", "pending"], ["target_id", 1596], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.163817"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1596 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1596 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1912 [["state", "sent"], ["updated_at", "2015-09-28 03:42:45.179153"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1596 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1912 [["sent_time", "2015-09-28 03:42:45.181793"], ["updated_at", "2015-09-28 03:42:45.183934"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1912]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1596]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1596 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1596 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1596 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'dBIA1l9LKOc6SbOEu6XpTwQzjQx4ZdgL05VpXvqsQJpg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.193018"], ["target_id", 1596], ["target_type", "User"], ["token", "dBIA1l9LKOc6SbOEu6XpTwQzjQx4ZdgL05VpXvqsQJpg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.193018"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.7ms Sent mail to user@example.com (1.7ms) Date: Mon, 28 Sep 2015 13:42:45 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b7353004d_10b393fd4cc860200275a4@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.201308"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.201308"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1597 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.204857"], ["state", "pending"], ["target_id", 1597], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.204857"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1913]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1597]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1597 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1597 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.214127"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.214127"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1598 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.218817"], ["state", "pending"], ["target_id", 1598], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.218817"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1914]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1598]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1598 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1598]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1598 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1914 [["sent_time", "2015-09-28 03:42:45.224251"], ["state", "sent"], ["updated_at", "2015-09-28 03:42:45.226783"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1598 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.233282"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.233282"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.236565"], ["state", "pending"], ["target_id", 1599], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.236565"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.240392"], ["state", "pending"], ["target_id", 1599], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.240392"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1916]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1599]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1599 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1599]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1916 [["sent_time", "2015-09-28 03:42:45.245462"], ["state", "sent"], ["updated_at", "2015-09-28 03:42:45.248137"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1599]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1915 [["sent_time", "2015-09-28 03:42:45.249846"], ["state", "sent"], ["updated_at", "2015-09-28 03:42:45.252468"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.260746"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.260746"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.264084"], ["state", "read"], ["target_id", 1600], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.264084"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1917]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1600]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1600 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.273943"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.273943"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.279308"], ["group_id", 2], ["state", "pending"], ["target_id", 1601], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.279308"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1918]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1601]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1601 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1601]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.5ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 1918 [["sent_time", "2015-09-28 03:42:45.284755"], ["state", "sent"], ["updated_at", "2015-09-28 03:42:45.290972"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1918]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1601]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1601 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'DIm6M5-Uk36FpGrWaU-m_gTdS_n3mbKbdEZSaOm93wTQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.308166"], ["target_id", 1601], ["target_type", "User"], ["token", "DIm6M5-Uk36FpGrWaU-m_gTdS_n3mbKbdEZSaOm93wTQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.308166"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.6ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 13:42:45 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b7354c14c_10b393fd4cc8602002769@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.315675"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.315675"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.321579"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1602], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.321579"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1919 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.325965"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1919 [["sent_time", "2015-09-28 03:42:45.327289"], ["updated_at", "2015-09-28 03:42:45.330084"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1919]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.337310"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.337310"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1603 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1603 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.344287"], ["group_id", 1], ["state", "pending"], ["target_id", 1603], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.344287"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1603 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1920) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.365274"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.365274"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1604 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1604 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.370806"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1604], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.370806"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1604 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1604 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.375403"], ["group_id", 1], ["state", "pending"], ["target_id", 1604], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.375403"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1604 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1922) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.381641"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.381641"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.386424"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1605], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.386424"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.391094"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1605], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.391094"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.395879"], ["group_id", 1], ["state", "pending"], ["target_id", 1605], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.395879"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1605 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1925) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.403608"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.403608"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1606 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1606 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.408782"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 1606], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.408782"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1606 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1606 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.413413"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 1606], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.413413"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1606 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1606 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.417760"], ["group_id", 1], ["state", "pending"], ["target_id", 1606], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.417760"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1606 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1928) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.423720"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.423720"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.428752"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1607], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.428752"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.434001"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1607], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.434001"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.439638"], ["group_id", 1], ["state", "pending"], ["target_id", 1607], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.439638"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1607 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1931) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.446823"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.446823"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1608 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1608 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 17:42:45.448315"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1608], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.452104"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1608 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:42:45.454760') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1608 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:42:45.454760') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1608 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1608 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:42:45.461311"], ["group_id", 1], ["parent_id", 1932], ["state", "pending"], ["target_id", 1608], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.461311"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.465676"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.465676"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1609 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1609 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:42:45.467044"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1609], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.470567"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1609 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:42:45.472761')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1609 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1609 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.477239"], ["group_id", 1], ["state", "pending"], ["target_id", 1609], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.477239"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.482478"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.482478"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1610 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1610 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:42:45.484326"], ["group_id", 1], ["state", "pending"], ["target_id", 1610], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.487910"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1610 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:42:45.490672')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1610 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1610 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.494648"], ["group_id", 1], ["state", "pending"], ["target_id", 1610], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.494648"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.499005"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.499005"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1611 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1611 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.503945"], ["group_id", 1], ["state", "pending"], ["target_id", 1611], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.503945"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1611 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1938) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1611 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1938) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.512661"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.512661"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.518690"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1612], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.518690"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1939 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.524198"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1939 [["sent_time", "2015-09-28 03:42:45.525452"], ["updated_at", "2015-09-28 03:42:45.528632"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.535633"], ["group_id", 1], ["state", "pending"], ["target_id", 1612], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.535633"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1612 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1940) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1612 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1940) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.544509"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.544509"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.550122"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1613], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.550122"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1941 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.555095"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1941 [["sent_time", "2015-09-28 03:42:45.556552"], ["updated_at", "2015-09-28 03:42:45.560185"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.565799"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1613], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.565799"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1942 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.570258"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1942 [["sent_time", "2015-09-28 03:42:45.571411"], ["updated_at", "2015-09-28 03:42:45.574045"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.579417"], ["group_id", 1], ["state", "pending"], ["target_id", 1613], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.579417"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1613 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1943) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1613 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1943) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.588831"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.588831"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.593271"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1614], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.593271"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1944 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.597717"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1944 [["sent_time", "2015-09-28 03:42:45.598899"], ["updated_at", "2015-09-28 03:42:45.601564"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.605845"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1614], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.605845"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1945 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.610029"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1945 [["sent_time", "2015-09-28 03:42:45.611316"], ["updated_at", "2015-09-28 03:42:45.614111"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.618673"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1614], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.618673"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1946 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.623211"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1946 [["sent_time", "2015-09-28 03:42:45.624371"], ["updated_at", "2015-09-28 03:42:45.626959"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.632349"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1614], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.632349"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1947 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.637458"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1947 [["sent_time", "2015-09-28 03:42:45.638856"], ["updated_at", "2015-09-28 03:42:45.641668"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.646338"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1614], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.646338"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1948 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.650667"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1948 [["sent_time", "2015-09-28 03:42:45.651886"], ["updated_at", "2015-09-28 03:42:45.654910"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.659405"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1614], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.659405"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.8ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1949 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.670997"]]  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1949 [["sent_time", "2015-09-28 03:42:45.675010"], ["updated_at", "2015-09-28 03:42:45.681496"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.685871"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1614], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.685871"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1950 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.690393"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1950 [["sent_time", "2015-09-28 03:42:45.691553"], ["updated_at", "2015-09-28 03:42:45.694337"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.699017"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1614], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.699017"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1951 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.703273"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1951 [["sent_time", "2015-09-28 03:42:45.704631"], ["updated_at", "2015-09-28 03:42:45.707075"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.711660"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1614], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.711660"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1952 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.717090"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1952 [["sent_time", "2015-09-28 03:42:45.718214"], ["updated_at", "2015-09-28 03:42:45.720939"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.725406"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1614], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.725406"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1953 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.729534"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1953 [["sent_time", "2015-09-28 03:42:45.730760"], ["updated_at", "2015-09-28 03:42:45.733326"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.738113"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1614], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.738113"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1954 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.742297"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1954 [["sent_time", "2015-09-28 03:42:45.743633"], ["updated_at", "2015-09-28 03:42:45.746783"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.751268"], ["group_id", 1], ["state", "pending"], ["target_id", 1614], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.751268"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1614 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1955) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1614 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 1955) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.759498"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.759498"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1615 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1615 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.764230"], ["group_id", 1], ["state", "pending"], ["target_id", 1615], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.764230"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1615 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1615 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1615 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1956)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1615 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1615 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1956 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.772402"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.777199"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.777199"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1616 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1616 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.785240"], ["group_id", 1], ["state", "pending"], ["target_id", 1616], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.785240"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1616 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1616 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1616 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1957)  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1616 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1616 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1957 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.796273"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.6ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.803959"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.803959"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1  (1.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1617 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1617 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.818972"], ["group_id", 1], ["state", "pending"], ["target_id", 1617], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.818972"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1617 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1617 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1617 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1958)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1617 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1617 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1958 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.827586"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1958]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.833882"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.833882"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.838505"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1618], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.838505"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:45.838505"], ["group_id", 1], ["state", "pending"], ["target_id", 1618], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.843631"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1618 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1960)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1960 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:42:45.853512"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.858820"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.858820"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1619 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1619 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.863858"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1619], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.863858"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1619 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:42:45.866260') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1619 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:42:45.866260') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1619 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1619 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:44:45.863858"], ["group_id", 1], ["parent_id", 1961], ["state", "pending"], ["target_id", 1619], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.871569"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1962]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.876552"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.876552"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.881076"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1620], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.881076"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.885398"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1620], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.885398"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.889596"], ["group_id", 1], ["state", "pending"], ["target_id", 1620], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.889596"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1620 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1965)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.899296"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.899296"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1621 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1621 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.903655"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1621], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.903655"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1621 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1621 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.908286"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1621], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.908286"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1621 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1621 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:45.912353"], ["group_id", 1], ["state", "pending"], ["target_id", 1621], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.912353"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1621 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1621 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1621 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 1968) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1968]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.922318"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.922318"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1622 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.928062"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.928062"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1623 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1623 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.935012"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.935012"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1624 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.940871"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.940871"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1625 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.944813"], ["state", "pending"], ["target_id", 1625], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.944813"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1625) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:45.949115"], ["target_id", 1625], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.949115"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1625 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.954386"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.954386"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.958213"], ["state", "pending"], ["target_id", 1626], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.958213"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.963755"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.963755"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.976075"], ["state", "pending"], ["target_id", 1627], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.976075"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1627) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:45.982233"], ["target_id", 1627], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:42:45.982233"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.989052"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.989052"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1628 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:45.992294"], ["state", "pending"], ["target_id", 1628], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:45.992294"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1628 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1628 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:45.999328"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:45.999328"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1629 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.002914"], ["state", "pending"], ["target_id", 1629], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.002914"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1629) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.005948"], ["group_id", 1], ["target_id", 1629], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.005948"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1629 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1629 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.4ms) BEGIN  (0.7ms) SAVEPOINT active_record_1 SQL (1.0ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.018206"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.018206"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1630 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.029569"], ["state", "pending"], ["target_id", 1630], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.029569"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1630) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:46.033698"], ["target_id", 1630], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.033698"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1630 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1630 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.041023"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.041023"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1631 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.044193"], ["state", "pending"], ["target_id", 1631], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.044193"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1631 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1631 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1975 [["group_id", 1], ["updated_at", "2015-09-28 03:42:46.048555"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1631 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1631 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.055186"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.055186"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1632 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.058389"], ["state", "pending"], ["target_id", 1632], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.058389"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1976]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1632]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1632 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1632 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.066667"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.066667"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1633 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.070112"], ["state", "pending"], ["target_id", 1633], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.070112"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1633) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:46.073326"], ["target_id", 1633], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:42:46.073326"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1977]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1633]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1633 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1633 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.082346"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.082346"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1634 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.085691"], ["state", "pending"], ["target_id", 1634], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.085691"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1634) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.088678"], ["group_id", 1], ["target_id", 1634], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.088678"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1634 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 1978]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1634]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1634 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.097778"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.097778"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1635 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.101602"], ["state", "pending"], ["target_id", 1635], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.101602"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1635 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1635 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.108835"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.108835"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1636 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.8ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.113058"], ["state", "pending"], ["target_id", 1636], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.113058"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (1.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1636) LIMIT 1 SQL (0.6ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:46.123595"], ["target_id", 1636], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:42:46.123595"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1636 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1636 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.135767"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.135767"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1637 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.139391"], ["state", "pending"], ["target_id", 1637], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.139391"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1637) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.142560"], ["group_id", 1], ["target_id", 1637], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.142560"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1637 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1637 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.149861"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.149861"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1638 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.153605"], ["state", "pending"], ["target_id", 1638], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.153605"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1638 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ggEVHgPy_rjNLBKcGgAxRQPB6Pa341fmLGNpomJYyNmw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.156904"], ["target_id", 1638], ["target_type", "User"], ["token", "ggEVHgPy_rjNLBKcGgAxRQPB6Pa341fmLGNpomJYyNmw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.156904"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.161852"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.161852"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1639 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.165061"], ["state", "pending"], ["target_id", 1639], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.165061"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1639 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'qdjiiX8JQ4J_onKN1h6O6QeBXQzPgSr3yqmlTpRkFyRQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.168457"], ["target_id", 1639], ["target_type", "User"], ["token", "qdjiiX8JQ4J_onKN1h6O6QeBXQzPgSr3yqmlTpRkFyRQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.168457"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1639 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.175176"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.175176"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1640 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.179851"], ["state", "pending"], ["target_id", 1640], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.179851"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1640 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'boHjmcMOJAdc6qA8HGQASgvZpcXIwktR8WIfC7XiLEaQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.184204"], ["target_id", 1640], ["target_type", "User"], ["token", "boHjmcMOJAdc6qA8HGQASgvZpcXIwktR8WIfC7XiLEaQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.184204"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 203 [["active", "f"], ["updated_at", "2015-09-28 03:42:46.187127"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1640 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'qHeExIH76eko-o100M5cCQN1_--7fJ03Y1vML_beUyYg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.190397"], ["target_id", 1640], ["target_type", "User"], ["token", "qHeExIH76eko-o100M5cCQN1_--7fJ03Y1vML_beUyYg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.190397"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.195346"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.195346"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.7ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1641 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.4ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (1.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1641) LIMIT 1 SQL (0.7ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:46.205304"], ["target_id", 1641], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.205304"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.4ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.214982"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.214982"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1642 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1642) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:46.219595"], ["target_id", 1642], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.219595"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1642 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.225175"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.225175"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (1.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1643) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:46.231036"], ["target_id", 1643], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.231036"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.7ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1643 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 343]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.241441"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.241441"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1644) LIMIT 1 SQL (1.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:46.245606"], ["target_id", 1644], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-28 03:42:46.245606"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (1.2ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1644 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.6ms) ROLLBACK  (0.3ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.264294"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.264294"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.7ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1645) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.269154"], ["group_id", 1], ["target_id", 1645], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.269154"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1645 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 345]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.277502"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.277502"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1646) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.281195"], ["group_id", 1], ["target_id", 1646], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.281195"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1646 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.287737"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.287737"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1647) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:46.291005"], ["target_id", 1647], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.291005"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1647 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.8ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.298250"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.298250"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1648) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:46.303055"], ["target_id", 1648], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.303055"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1648 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.309528"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.309528"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1649) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:42:46.312678"], ["target_id", 1649], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.312678"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1649) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1649 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1649 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 349]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1649 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.325020"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.325020"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1650 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.329792"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.329792"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'N_PaClJzT9CNYI3Z6t57cALab9Lshz3p6D-ItAdqMqKw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.331752"], ["target_id", 1651], ["target_type", "User"], ["token", "N_PaClJzT9CNYI3Z6t57cALab9Lshz3p6D-ItAdqMqKw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.331752"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'N_PaClJzT9CNYI3Z6t57cALab9Lshz3p6D-ItAdqMqKw' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.337475"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.337475"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ukp0pi4ynLXYR29ufWm9sQ7C_rVvkthMyRBca2OQ9PLA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.340049"], ["target_id", 1652], ["target_type", "User"], ["token", "ukp0pi4ynLXYR29ufWm9sQ7C_rVvkthMyRBca2OQ9PLA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.340049"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 206 [["active", "f"], ["updated_at", "2015-09-28 03:42:46.343635"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ukp0pi4ynLXYR29ufWm9sQ7C_rVvkthMyRBca2OQ9PLA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.347679"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.347679"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Y12nl4imhRmhA2AJ9o52EwFj2tKoHcy-CV2rAh3dVmeQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.349570"], ["target_id", 1653], ["target_type", "User"], ["token", "Y12nl4imhRmhA2AJ9o52EwFj2tKoHcy-CV2rAh3dVmeQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.349570"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 207 [["active", "f"], ["updated_at", "2015-09-28 03:42:46.353118"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (1.1ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.356740"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:42:46.356740"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'xrVGL9gyRCaxSRFcCu-dxwJRkH5HHUy75GF_yMlWBxHQ' LIMIT 1 SQL (0.8ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:42:46.360914"], ["target_id", 1654], ["target_type", "User"], ["token", "xrVGL9gyRCaxSRFcCu-dxwJRkH5HHUy75GF_yMlWBxHQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.360914"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.6ms) ROLLBACK  (0.3ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.378556"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-28 03:42:46.378556"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1655 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:46.382630"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1655], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.382630"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:42:46.387828"], ["email", "2@notifyuser.com"], ["updated_at", "2015-09-28 03:42:46.387828"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1656 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:42:46.390950"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1656], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:42:46.390950"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:17.648096"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:17.648096"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.3ms) Completed 200 OK in 23ms (Views: 17.5ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:17.687872"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:17.687872"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1658 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:17.716936"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1658], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:17.716936"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1658 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1658 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 15ms  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:17.741436"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:17.741436"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1659 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:17.747908"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1659], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:17.747908"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1659 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1659 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:17.761530"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:17.761530"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1660 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:17.767537"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1660], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:17.767537"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1660 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:17.771131"], ["parent_id", 1], ["state", "pending"], ["target_id", 1660], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:17.771131"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1660 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (1.0ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1660 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:17.785792"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:17.785792"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1661 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:17.791279"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1661], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:17.791279"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1661 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:17.794699"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1661], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:17.794699"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1661 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:17.798296"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1661], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:17.798296"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1661 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 174ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:17.984049"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:17.984049"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1662 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:17.993144"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1662], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:17.993144"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1662 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:18.002471"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1662], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.002471"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1662 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:18.006563"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1662], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.006563"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1994"} NotifyUser::BaseNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1662 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1994') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1662]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1662 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1994 [["state", "read"], ["updated_at", "2015-09-28 03:43:18.021371"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 16ms (Views: 1.8ms | ActiveRecord: 2.0ms) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 1994 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.037371"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.037371"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:18.044053"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1663], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.044053"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:18.047771"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1663], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.047771"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:18.051647"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1663], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.051647"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1997"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1663 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1997') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1663]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 1997 [["state", "read"], ["updated_at", "2015-09-28 03:43:18.061718"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.3ms | ActiveRecord: 1.7ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"1997"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1663 AND "notify_user_notifications"."target_type" = 'User' AND (id = '1997') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.3ms | ActiveRecord: 2.1ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.072580"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.072580"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:18.079702"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1664], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.079702"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:18.083470"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1664], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.083470"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:18.086928"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1664], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.086928"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1664 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1664 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 3ms (Views: 0.8ms | ActiveRecord: 0.9ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1664 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.100242"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.100242"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 3ms (Views: 1.8ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.118206"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.118206"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 3ms (Views: 1.9ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.134566"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.134566"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1667 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:18.141891"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1667], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.141891"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["2003"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1667 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2003')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1667 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2003')) Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.158105"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.158105"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1668 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:18.166326"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1668], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.166326"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["2004"]} SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1668 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2004')) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1668 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2004')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.183970"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.183970"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1669 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:18.192976"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1669], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.192976"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.7ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1669 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (1.0ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1669 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1669) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:18.222652"], ["target_id", 1669], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.222652"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1669 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 26ms (Views: 2.4ms | ActiveRecord: 2.5ms) NotifyUser::Unsubscribe Load (0.6ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1669 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.237333"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.237333"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1670 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:18.244446"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1670], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.244446"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1670 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1670 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1670 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 18ms (Views: 13.3ms | ActiveRecord: 0.8ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1670 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.275414"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.275414"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1671 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:18.283423"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1671], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.283423"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1671 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1671) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:18.291345"], ["target_id", 1671], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.291345"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1671 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 8ms (ActiveRecord: 1.8ms) NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.4ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.302540"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.302540"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1672 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:18.308515"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1672], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.308515"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1672) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:18.312028"], ["target_id", 1672], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.312028"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1672 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 352]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 4ms (ActiveRecord: 1.1ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.326755"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.326755"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1673 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:18.335045"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1673], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.335045"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1673 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.5ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'egl2LDRdSRXAzL0YetQoQwdWnJLWIm9cZnyE0WLu3ICA' LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.345622"], ["target_id", 1673], ["target_type", "User"], ["token", "egl2LDRdSRXAzL0YetQoQwdWnJLWIm9cZnyE0WLu3ICA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.345622"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"egl2LDRdSRXAzL0YetQoQwdWnJLWIm9cZnyE0WLu3ICA"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'egl2LDRdSRXAzL0YetQoQwdWnJLWIm9cZnyE0WLu3ICA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'egl2LDRdSRXAzL0YetQoQwdWnJLWIm9cZnyE0WLu3ICA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1673]]  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1673) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:18.356333"], ["target_id", 1673], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.356333"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 209 [["active", "f"], ["updated_at", "2015-09-28 03:43:18.357993"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.3ms | ActiveRecord: 2.4ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.364389"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.364389"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1674 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.368228"], ["state", "pending"], ["target_id", 1674], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.368228"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1674 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1674 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.377672"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.377672"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1675 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.382808"], ["state", "pending"], ["target_id", 1675], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.382808"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1675 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1675 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.392458"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.392458"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1676 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.396509"], ["state", "pending"], ["target_id", 1676], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.396509"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1676 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.404367"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.404367"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1677 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.407711"], ["state", "pending"], ["target_id", 1677], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.407711"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1677 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 27.2ms NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.2ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.5ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.694498"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.694498"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1678 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.698647"], ["state", "pending"], ["target_id", 1678], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.698647"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1678 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.704959"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.704959"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1679 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.708412"], ["state", "pending"], ["target_id", 1679], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.708412"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1679 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.715646"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.715646"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1680 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.719923"], ["state", "pending"], ["target_id", 1680], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.719923"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1680 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.733434"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.733434"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1681 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.740637"], ["state", "pending"], ["target_id", 1681], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.740637"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1681 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.750425"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.750425"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1682 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.754363"], ["state", "pending"], ["target_id", 1682], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.754363"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1682 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.760011"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.760011"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1683 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.764544"], ["state", "pending"], ["target_id", 1683], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.764544"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.768824"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.768824"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1684 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.771968"], ["state", "pending"], ["target_id", 1684], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.771968"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.775957"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.775957"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1685 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.779758"], ["state", "pending"], ["target_id", 1685], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.779758"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1685 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2021 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:43:18.783468"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.788782"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.788782"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1686 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.792068"], ["state", "pending"], ["target_id", 1686], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.792068"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1686 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2022 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:43:18.794951"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.800510"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.800510"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1687 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.803695"], ["state", "pending"], ["target_id", 1687], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.803695"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1687 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2023 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:43:18.806767"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.812311"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.812311"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1688 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.816261"], ["state", "pending"], ["target_id", 1688], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.816261"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1688 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2024 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:43:18.819169"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.824623"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.824623"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1689 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.827752"], ["state", "pending"], ["target_id", 1689], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.827752"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1689 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2025]]  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.853256"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.853256"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1690 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.856449"], ["state", "pending"], ["target_id", 1690], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.856449"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1690 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2026]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.864480"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.864480"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1691 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.867890"], ["state", "pending"], ["target_id", 1691], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.867890"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.872365"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.872365"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1692 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.875528"], ["state", "pending"], ["target_id", 1692], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.875528"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1692 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1692 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2028)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1692 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2028 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:18.882020"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2028]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1692]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1692 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1692]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1692 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2028 [["sent_time", "2015-09-28 03:43:18.887932"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:18.890588"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1692 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2028]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1692]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1692 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1692 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1692 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'RAg7Ed2ZUIX5o48eM3eyXA3E4q1P1laslzlXjn38WeTw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.901456"], ["target_id", 1692], ["target_type", "User"], ["token", "RAg7Ed2ZUIX5o48eM3eyXA3E4q1P1laslzlXjn38WeTw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.901456"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.8ms Sent mail to user@example.com (4.5ms) Date: Mon, 28 Sep 2015 13:43:18 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b756dd4c5_10d3a3fe54d8281fc3347f@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.912169"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.912169"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1693 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.916626"], ["state", "pending_as_aggregation_parent"], ["target_id", 1693], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.916626"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1693 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.920383"], ["state", "pending"], ["target_id", 1693], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.920383"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1693 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1693 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2030)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.927470"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.927470"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1694 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.930941"], ["state", "pending"], ["target_id", 1694], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.930941"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1694 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1694 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2031 [["state", "sent"], ["updated_at", "2015-09-28 03:43:18.934960"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1694 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2031 [["sent_time", "2015-09-28 03:43:18.936094"], ["updated_at", "2015-09-28 03:43:18.937491"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2031]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1694]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1694 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1694 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1694 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'sgsZYveCe0d6y2vy1hBRaAXpylvXGT5na1IANlzd_wXw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.946442"], ["target_id", 1694], ["target_type", "User"], ["token", "sgsZYveCe0d6y2vy1hBRaAXpylvXGT5na1IANlzd_wXw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.946442"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.8ms Sent mail to user@example.com (1.7ms) Date: Mon, 28 Sep 2015 13:43:18 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b756e7fb8_10d3a3fe54d8281fc33512@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.954004"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.954004"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1695 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.957393"], ["state", "pending"], ["target_id", 1695], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.957393"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1695 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2032 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 03:43:18.960380"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.965626"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.965626"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1696 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.968857"], ["state", "pending"], ["target_id", 1696], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.968857"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1696) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:18.972582"], ["target_id", 1696], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:43:18.972582"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2033]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1696]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1696 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1696 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.980907"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.980907"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1697 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.984134"], ["state", "pending"], ["target_id", 1697], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.984134"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2034]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1697]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1697 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1697 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:18.991949"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:18.991949"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1698 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:18.995200"], ["state", "pending"], ["target_id", 1698], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:18.995200"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1698 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1698 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2035 [["state", "sent"], ["updated_at", "2015-09-28 03:43:19.000293"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1698 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2035 [["sent_time", "2015-09-28 03:43:19.001651"], ["updated_at", "2015-09-28 03:43:19.003223"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2035]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1698]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1698 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1698 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1698 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.5ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'RjLFpEZr0-_oNyZkIUyY6gYyJg3kGa3WQoWQZI672y4g' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.011468"], ["target_id", 1698], ["target_type", "User"], ["token", "RjLFpEZr0-_oNyZkIUyY6gYyJg3kGa3WQoWQZI672y4g"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.011468"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.5ms Sent mail to user@example.com (1.7ms) Date: Mon, 28 Sep 2015 13:43:19 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b7573f30_10d3a3fe54d8281fc33686@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.020124"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.020124"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1699 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.023337"], ["state", "pending"], ["target_id", 1699], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.023337"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2036]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1699]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1699 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1699 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.031440"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.031440"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1700 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.035076"], ["state", "pending"], ["target_id", 1700], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.035076"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2037]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1700]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1700 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1700]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1700 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2037 [["sent_time", "2015-09-28 03:43:19.039472"], ["state", "sent"], ["updated_at", "2015-09-28 03:43:19.041839"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1700 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.048506"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.048506"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1701 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.051972"], ["state", "pending"], ["target_id", 1701], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.051972"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1701 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.055969"], ["state", "pending"], ["target_id", 1701], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.055969"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2039]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1701]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1701 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1701]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1701 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2039 [["sent_time", "2015-09-28 03:43:19.060610"], ["state", "sent"], ["updated_at", "2015-09-28 03:43:19.063968"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1701]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1701 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2038 [["sent_time", "2015-09-28 03:43:19.065814"], ["state", "sent"], ["updated_at", "2015-09-28 03:43:19.068387"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1701 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1701 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.076565"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.076565"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1702 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.080160"], ["state", "read"], ["target_id", 1702], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.080160"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2040]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1702]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1702 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.087981"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.087981"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.092208"], ["group_id", 2], ["state", "pending"], ["target_id", 1703], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.092208"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2041]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1703]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1703 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1703]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2041 [["sent_time", "2015-09-28 03:43:19.097519"], ["state", "sent"], ["updated_at", "2015-09-28 03:43:19.100800"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2041]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1703]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1703 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'dLOzU2vlALn6fw2OoGPGQAzKbWN1JfBPEUB7PCkm5D3w' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.114355"], ["target_id", 1703], ["target_type", "User"], ["token", "dLOzU2vlALn6fw2OoGPGQAzKbWN1JfBPEUB7PCkm5D3w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.114355"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.5ms Sent mail to user@example.com (1.6ms) Date: Mon, 28 Sep 2015 13:43:19 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b7571cc5d_10d3a3fe54d8281fc337a1@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.121760"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.121760"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1704 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1704 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.126398"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1704], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.126398"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1704 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1704 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2042 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.130721"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1704 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1704 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2042 [["sent_time", "2015-09-28 03:43:19.132141"], ["updated_at", "2015-09-28 03:43:19.135910"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2042]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.144614"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.144614"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1705 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1705 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.148922"], ["group_id", 1], ["state", "pending"], ["target_id", 1705], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.148922"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1705 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2043) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.155278"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.155278"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1706 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1706 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.174870"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1706], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.174870"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1706 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1706 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.180330"], ["group_id", 1], ["state", "pending"], ["target_id", 1706], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.180330"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1706 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2045) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.3ms) ROLLBACK  (0.3ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.191136"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.191136"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1707 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1707 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.199931"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1707], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.199931"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1707 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1707 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.205238"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1707], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.205238"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1707 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1707 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.210378"], ["group_id", 1], ["state", "pending"], ["target_id", 1707], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.210378"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1707 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2048) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.217175"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.217175"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1708 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1708 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.223442"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 1708], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.223442"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1708 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1708 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.229294"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 1708], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.229294"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1708 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1708 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.234261"], ["group_id", 1], ["state", "pending"], ["target_id", 1708], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.234261"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1708 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2051) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.240518"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.240518"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1709 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1709 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.245224"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1709], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.245224"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1709 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1709 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.249964"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1709], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.249964"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1709 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1709 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.254804"], ["group_id", 1], ["state", "pending"], ["target_id", 1709], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.254804"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1709 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2054) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.261819"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.261819"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1710 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1710 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 17:43:19.262918"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1710], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.266352"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1710 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:43:19.268661') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1710 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:43:19.268661') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1710 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1710 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:43:19.274771"], ["group_id", 1], ["parent_id", 2055], ["state", "pending"], ["target_id", 1710], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.274771"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.280217"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.280217"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1711 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1711 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:43:19.281559"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1711], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.285355"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1711 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:43:19.287759')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1711 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1711 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.292152"], ["group_id", 1], ["state", "pending"], ["target_id", 1711], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.292152"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.296702"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.296702"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1712 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1712 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:43:19.297888"], ["group_id", 1], ["state", "pending"], ["target_id", 1712], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.302227"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1712 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:43:19.305194')  (0.3ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1712 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1712 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.309997"], ["group_id", 1], ["state", "pending"], ["target_id", 1712], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.309997"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.314970"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.314970"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1713 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1713 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.319376"], ["group_id", 1], ["state", "pending"], ["target_id", 1713], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.319376"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1713 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2061) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1713 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2061) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.327400"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.327400"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.333655"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1714], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.333655"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2062 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.339213"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2062 [["sent_time", "2015-09-28 03:43:19.340435"], ["updated_at", "2015-09-28 03:43:19.343240"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.348321"], ["group_id", 1], ["state", "pending"], ["target_id", 1714], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.348321"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1714 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2063) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1714 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2063) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.357664"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.357664"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.362469"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1715], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.362469"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2064 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.367561"]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2064 [["sent_time", "2015-09-28 03:43:19.369876"], ["updated_at", "2015-09-28 03:43:19.373991"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.380363"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1715], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.380363"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2065 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.385188"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2065 [["sent_time", "2015-09-28 03:43:19.386430"], ["updated_at", "2015-09-28 03:43:19.388862"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.393738"], ["group_id", 1], ["state", "pending"], ["target_id", 1715], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.393738"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1715 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2066) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1715 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2066) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.401773"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.401773"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.406807"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1716], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.406807"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2067 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.412015"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2067 [["sent_time", "2015-09-28 03:43:19.413301"], ["updated_at", "2015-09-28 03:43:19.415746"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.420363"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1716], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.420363"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2068 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.424633"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2068 [["sent_time", "2015-09-28 03:43:19.425854"], ["updated_at", "2015-09-28 03:43:19.428441"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.432943"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1716], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.432943"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2069 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.438239"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2069 [["sent_time", "2015-09-28 03:43:19.439741"], ["updated_at", "2015-09-28 03:43:19.442410"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.447945"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1716], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.447945"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2070 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.452647"]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2070 [["sent_time", "2015-09-28 03:43:19.453863"], ["updated_at", "2015-09-28 03:43:19.456974"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.461488"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1716], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.461488"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2071 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.465975"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2071 [["sent_time", "2015-09-28 03:43:19.467167"], ["updated_at", "2015-09-28 03:43:19.469855"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.474545"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1716], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.474545"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2072 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.479023"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2072 [["sent_time", "2015-09-28 03:43:19.480350"], ["updated_at", "2015-09-28 03:43:19.482979"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.487571"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1716], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.487571"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2073 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.491885"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2073 [["sent_time", "2015-09-28 03:43:19.493115"], ["updated_at", "2015-09-28 03:43:19.495421"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.499769"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1716], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.499769"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2074 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.503627"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2074 [["sent_time", "2015-09-28 03:43:19.505037"], ["updated_at", "2015-09-28 03:43:19.507808"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.512525"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1716], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.512525"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2075 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.517084"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2075 [["sent_time", "2015-09-28 03:43:19.518325"], ["updated_at", "2015-09-28 03:43:19.521027"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.525395"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1716], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.525395"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2076 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.529661"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2076 [["sent_time", "2015-09-28 03:43:19.530999"], ["updated_at", "2015-09-28 03:43:19.533647"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.538348"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1716], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.538348"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2077 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.542354"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2077 [["sent_time", "2015-09-28 03:43:19.543513"], ["updated_at", "2015-09-28 03:43:19.545945"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.550478"], ["group_id", 1], ["state", "pending"], ["target_id", 1716], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.550478"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1716 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2078) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1716 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2078) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.558489"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.558489"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1717 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1717 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.562982"], ["group_id", 1], ["state", "pending"], ["target_id", 1717], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.562982"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1717 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1717 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1717 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2079)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1717 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1717 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2079 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.572006"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.577370"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.577370"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1718 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1718 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.582319"], ["group_id", 1], ["state", "pending"], ["target_id", 1718], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.582319"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1718 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1718 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1718 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2080)  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1718 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1718 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2080 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.592458"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.598116"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.598116"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1719 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1719 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.602732"], ["group_id", 1], ["state", "pending"], ["target_id", 1719], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.602732"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1719 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1719 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1719 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2081)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1719 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1719 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2081 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.611177"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2081]]  (0.5ms) ROLLBACK  (0.3ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.622164"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.622164"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.627960"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1720], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.627960"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:45:19.627960"], ["group_id", 1], ["state", "pending"], ["target_id", 1720], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.636866"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1720 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2083)  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2083 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:43:19.647042"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.651694"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.651694"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1721 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1721 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.656581"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1721], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.656581"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1721 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:43:19.658822') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1721 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:43:19.658822') ORDER BY created_at DESC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1721 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1721 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:45:19.656581"], ["group_id", 1], ["parent_id", 2084], ["state", "pending"], ["target_id", 1721], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.663906"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2085]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.668908"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.668908"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.672889"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1722], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.672889"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.676923"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1722], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.676923"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.680999"], ["group_id", 1], ["state", "pending"], ["target_id", 1722], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.680999"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1722 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2088)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.689194"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.689194"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.694163"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1723], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.694163"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.699526"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1723], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.699526"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:19.704077"], ["group_id", 1], ["state", "pending"], ["target_id", 1723], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.704077"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1723 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2091) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2091]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.713483"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.713483"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1724 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.718867"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.718867"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1725 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1725 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.725401"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.725401"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1726 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.730821"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.730821"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.734210"], ["state", "pending"], ["target_id", 1727], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.734210"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1727) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:19.737189"], ["target_id", 1727], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.737189"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.741882"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.741882"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1728 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.746589"], ["state", "pending"], ["target_id", 1728], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.746589"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1728 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.752611"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.752611"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1729 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.755717"], ["state", "pending"], ["target_id", 1729], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.755717"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1729) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:19.758917"], ["target_id", 1729], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:43:19.758917"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1729 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1729 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.765245"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.765245"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1730 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.768715"], ["state", "pending"], ["target_id", 1730], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.768715"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1730 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1730 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.774465"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.774465"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1731 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.777455"], ["state", "pending"], ["target_id", 1731], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.777455"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1731) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.780699"], ["group_id", 1], ["target_id", 1731], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.780699"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1731 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1731 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.788252"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.788252"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1732 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.791542"], ["state", "pending"], ["target_id", 1732], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.791542"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1732) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:19.794631"], ["target_id", 1732], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.794631"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1732 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1732 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.802871"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.802871"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1733 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.806210"], ["state", "pending"], ["target_id", 1733], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.806210"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1733 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1733 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2098 [["group_id", 1], ["updated_at", "2015-09-28 03:43:19.810388"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1733 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1733 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.817796"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.817796"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1734 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.821052"], ["state", "pending"], ["target_id", 1734], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.821052"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2099]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1734]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1734 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1734 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.829169"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.829169"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1735 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.832845"], ["state", "pending"], ["target_id", 1735], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.832845"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1735) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:19.835797"], ["target_id", 1735], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:43:19.835797"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2100]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1735]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1735 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1735 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.842992"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.842992"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1736 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.846945"], ["state", "pending"], ["target_id", 1736], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.846945"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1736) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.850147"], ["group_id", 1], ["target_id", 1736], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.850147"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1736 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2101]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1736]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1736 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.8ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.859851"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.859851"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1737 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.863499"], ["state", "pending"], ["target_id", 1737], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.863499"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1737 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1737 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.870204"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.870204"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1738 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.873639"], ["state", "pending"], ["target_id", 1738], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.873639"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1738) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:19.876498"], ["target_id", 1738], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:43:19.876498"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1738 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1738 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.883075"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.883075"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1739 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.886402"], ["state", "pending"], ["target_id", 1739], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.886402"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1739) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.889361"], ["group_id", 1], ["target_id", 1739], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.889361"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1739 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1739 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.898469"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.898469"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1740 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.901776"], ["state", "pending"], ["target_id", 1740], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.901776"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1740 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'REOHFXFio-gN64aenl1j7Qtdjr5lSAGMRR2tzT8ZUUYw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.905354"], ["target_id", 1740], ["target_type", "User"], ["token", "REOHFXFio-gN64aenl1j7Qtdjr5lSAGMRR2tzT8ZUUYw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.905354"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.910105"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.910105"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1741 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.913324"], ["state", "pending"], ["target_id", 1741], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.913324"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1741 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '4TVjQxgp18B_vfqMQOsjYQww0HFh4YP6eZvNKNaQYnIw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.916833"], ["target_id", 1741], ["target_type", "User"], ["token", "4TVjQxgp18B_vfqMQOsjYQww0HFh4YP6eZvNKNaQYnIw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.916833"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1741 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.923248"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.923248"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1742 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.926543"], ["state", "pending"], ["target_id", 1742], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.926543"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1742 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'aJzyRFnbSPE0vkWTdRRyWAFtEM0b3QCTCAxNtoNRrJtQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.929941"], ["target_id", 1742], ["target_type", "User"], ["token", "aJzyRFnbSPE0vkWTdRRyWAFtEM0b3QCTCAxNtoNRrJtQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.929941"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 216 [["active", "f"], ["updated_at", "2015-09-28 03:43:19.932824"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1742 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'nEzErTqnUuaK2LKp6cetzwg8EabufNLciKnNUT7R5Cgg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.935964"], ["target_id", 1742], ["target_type", "User"], ["token", "nEzErTqnUuaK2LKp6cetzwg8EabufNLciKnNUT7R5Cgg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.935964"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.940579"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.940579"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1743 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1743) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:19.944312"], ["target_id", 1743], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.944312"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.948418"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.948418"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1744 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1744) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:19.952310"], ["target_id", 1744], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.952310"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1744 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.957571"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.957571"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1745) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:19.960359"], ["target_id", 1745], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.960359"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1745 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 365]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.966742"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.966742"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1746) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:19.969702"], ["target_id", 1746], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-28 03:43:19.969702"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1746 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.974869"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.974869"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1747) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.977675"], ["group_id", 1], ["target_id", 1747], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.977675"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1747 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 367]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.984108"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.984108"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1748) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:19.987003"], ["group_id", 1], ["target_id", 1748], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.987003"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1748 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:19.992100"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:19.992100"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1749) LIMIT 1 SQL (0.5ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:19.994962"], ["target_id", 1749], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:19.994962"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1749 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:20.000655"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:20.000655"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1750) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:20.003645"], ["target_id", 1750], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:20.003645"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1750 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:20.009588"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:20.009588"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1751) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:20.012359"], ["target_id", 1751], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:20.012359"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1751) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1751 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1751 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 371]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1751 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:20.022950"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:20.022950"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1752 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:20.027532"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:20.027532"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'hjvJJPAHGmv2rtAGDo7G-QtM5Xfu6XUGUfioqNfbdOiA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:20.029480"], ["target_id", 1753], ["target_type", "User"], ["token", "hjvJJPAHGmv2rtAGDo7G-QtM5Xfu6XUGUfioqNfbdOiA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:20.029480"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'hjvJJPAHGmv2rtAGDo7G-QtM5Xfu6XUGUfioqNfbdOiA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:20.035319"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:20.035319"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'bHAW8to9W2FU3H5WTzD9KwnS2SWeDapiwZbJYa4CyzHg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:20.036976"], ["target_id", 1754], ["target_type", "User"], ["token", "bHAW8to9W2FU3H5WTzD9KwnS2SWeDapiwZbJYa4CyzHg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:20.036976"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 219 [["active", "f"], ["updated_at", "2015-09-28 03:43:20.039925"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'bHAW8to9W2FU3H5WTzD9KwnS2SWeDapiwZbJYa4CyzHg' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:20.043603"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:20.043603"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'iewbb7a4bFlnZ_VBCwU4nQYpKiKXYUTDXHLt44f-kk1g' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:20.045882"], ["target_id", 1755], ["target_type", "User"], ["token", "iewbb7a4bFlnZ_VBCwU4nQYpKiKXYUTDXHLt44f-kk1g"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:20.045882"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 220 [["active", "f"], ["updated_at", "2015-09-28 03:43:20.049818"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:20.052915"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:20.052915"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'fX8v69ipcdMdzAJP8bnDRgRTTK-yU4GBOhu7yjjuZ-zg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:20.054945"], ["target_id", 1756], ["target_type", "User"], ["token", "fX8v69ipcdMdzAJP8bnDRgRTTK-yU4GBOhu7yjjuZ-zg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:20.054945"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:20.061765"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-28 03:43:20.061765"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1757 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:20.064909"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1757], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:20.064909"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:20.070013"], ["email", "2@notifyuser.com"], ["updated_at", "2015-09-28 03:43:20.070013"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1758 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:20.073163"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1758], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:20.073163"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:34.978039"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:34.978039"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.3ms) Completed 200 OK in 18ms (Views: 14.7ms | ActiveRecord: 0.0ms)  (0.4ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.010684"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.010684"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1760 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.036147"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1760], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.036147"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1760 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1760 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 12ms  (0.3ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.058600"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.058600"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1761 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.064285"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1761], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.064285"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1761 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1761 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.076753"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.076753"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1762 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.082317"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1762], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.082317"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1762 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.085944"], ["parent_id", 1], ["state", "pending"], ["target_id", 1762], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.085944"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1762 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1762 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.100145"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.100145"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1763 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.106864"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1763], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.106864"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1763 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.110494"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1763], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.110494"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1763 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.113742"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1763], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.113742"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1763 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 158ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.283297"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.283297"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1764 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.291005"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1764], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.291005"]]  (5.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1764 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.300305"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1764], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.300305"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1764 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.304682"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1764], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.304682"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"2117"} NotifyUser::BaseNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1764 AND "notify_user_notifications"."target_type" = 'User' AND (id = '2117') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.3ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1764]]  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1764 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2117 [["state", "read"], ["updated_at", "2015-09-28 03:43:35.321921"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 18ms (Views: 1.5ms | ActiveRecord: 2.7ms) NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 2117 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.335110"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.335110"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1765 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.341201"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1765], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.341201"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1765 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.345052"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1765], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.345052"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1765 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.349065"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1765], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.349065"]]  (0.5ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"2120"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1765 AND "notify_user_notifications"."target_type" = 'User' AND (id = '2120') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1765]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1765 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2120 [["state", "read"], ["updated_at", "2015-09-28 03:43:35.359176"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.3ms | ActiveRecord: 1.7ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"2120"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1765 AND "notify_user_notifications"."target_type" = 'User' AND (id = '2120') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.2ms | ActiveRecord: 2.1ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.369869"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.369869"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1766 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.376335"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1766], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.376335"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1766 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.379944"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1766], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.379944"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1766 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.383351"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1766], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.383351"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1766 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1766 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 4ms (Views: 1.0ms | ActiveRecord: 0.9ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1766 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.396650"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.396650"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 4ms (Views: 2.5ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.417063"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.417063"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 3ms (Views: 1.9ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.439660"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.439660"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1769 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.446292"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1769], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.446292"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["2126"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1769 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2126')) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1769 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2126')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.462290"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.462290"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1770 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.470529"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1770], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.470529"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["2127"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1770 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2127')) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1770 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2127')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.487332"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.487332"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.495164"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1771], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.495164"]]  (0.5ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.7ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1771) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:35.517631"], ["target_id", 1771], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.517631"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 22ms (Views: 2.3ms | ActiveRecord: 2.1ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.530744"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.530744"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.536920"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1772], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.536920"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 17ms (Views: 11.9ms | ActiveRecord: 0.7ms) NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.4ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.566322"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.566322"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1773 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.572984"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1773], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.572984"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1773 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1773) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:35.580375"], ["target_id", 1773], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.580375"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1773 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 8ms (ActiveRecord: 1.7ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.590933"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.590933"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1774 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.597310"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1774], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.597310"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1774) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:35.600156"], ["target_id", 1774], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.600156"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1774 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 374]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 4ms (ActiveRecord: 1.0ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.614549"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.614549"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1775 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:43:35.621405"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1775], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.621405"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1775 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'xMLikVsePAZzVEMwMAjypwL6wNxIRABCsjfHlTSlEi7w' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:35.632608"], ["target_id", 1775], ["target_type", "User"], ["token", "xMLikVsePAZzVEMwMAjypwL6wNxIRABCsjfHlTSlEi7w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.632608"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"xMLikVsePAZzVEMwMAjypwL6wNxIRABCsjfHlTSlEi7w"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'xMLikVsePAZzVEMwMAjypwL6wNxIRABCsjfHlTSlEi7w' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'xMLikVsePAZzVEMwMAjypwL6wNxIRABCsjfHlTSlEi7w' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1775]]  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1775) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:43:35.642566"], ["target_id", 1775], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.642566"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 222 [["active", "f"], ["updated_at", "2015-09-28 03:43:35.644578"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 9ms (Views: 0.3ms | ActiveRecord: 2.4ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.650350"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.650350"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1776 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:35.655215"], ["state", "pending"], ["target_id", 1776], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.655215"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1776 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1776 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.666306"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.666306"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1777 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:35.670322"], ["state", "pending"], ["target_id", 1777], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.670322"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1777 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1777 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.682279"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.682279"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1778 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:35.685920"], ["state", "pending"], ["target_id", 1778], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.685920"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1778 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.698712"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.698712"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1779 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:35.702645"], ["state", "pending"], ["target_id", 1779], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.702645"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1779 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 26.7ms NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.2ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.6ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.964127"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.964127"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1780 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:35.967701"], ["state", "pending"], ["target_id", 1780], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.967701"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1780 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.973956"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.973956"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1781 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:35.978455"], ["state", "pending"], ["target_id", 1781], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.978455"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1781 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.984378"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.984378"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1782 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:35.987651"], ["state", "pending"], ["target_id", 1782], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.987651"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1782 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:35.995814"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:35.995814"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1783 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:35.999132"], ["state", "pending"], ["target_id", 1783], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:35.999132"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1783 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:36.005394"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:36.005394"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1784 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:36.008877"], ["state", "pending"], ["target_id", 1784], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:36.008877"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1784 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:36.015271"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:36.015271"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1785 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:36.021003"], ["state", "pending"], ["target_id", 1785], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:36.021003"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:36.025352"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:36.025352"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1786 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:36.028768"], ["state", "pending"], ["target_id", 1786], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:36.028768"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:36.032860"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:36.032860"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1787 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:36.036035"], ["state", "pending"], ["target_id", 1787], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:36.036035"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1787 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2144 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:43:36.038943"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:36.044303"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:36.044303"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1788 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:36.047527"], ["state", "pending"], ["target_id", 1788], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:36.047527"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1788 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2145 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:43:36.050400"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:36.055322"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:36.055322"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:36.058612"], ["state", "pending"], ["target_id", 1789], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:36.058612"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2146 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:43:36.062562"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:36.067927"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:36.067927"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:36.071421"], ["state", "pending"], ["target_id", 1790], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:36.071421"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2147 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:43:36.074148"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:36.079390"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:36.079390"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1791 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:36.082738"], ["state", "pending"], ["target_id", 1791], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:36.082738"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1791 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2148]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:43:36.108318"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:43:36.108318"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1792 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:43:36.111653"], ["state", "pending"], ["target_id", 1792], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:43:36.111653"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1792 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2149]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2149]]  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:29.324996"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:29.324996"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.3ms) Completed 200 OK in 22ms (Views: 17.2ms | ActiveRecord: 0.0ms)  (1.0ms) ROLLBACK  (0.4ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:29.375908"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:29.375908"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1794 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.450679"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1794], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.450679"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.9ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1794 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1794 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 23ms  (1.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:29.486459"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:29.486459"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1795 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.493627"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1795], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.493627"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (1.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1795 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (1.1ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1795 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 19ms  (1.3ms) ROLLBACK  (0.3ms) BEGIN  (0.6ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:29.530442"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:29.530442"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1796 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.539484"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1796], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.539484"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1796 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.543221"], ["parent_id", 1], ["state", "pending"], ["target_id", 1796], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.543221"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1796 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1796 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.6ms) SAVEPOINT active_record_1 SQL (0.8ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:29.559417"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:29.559417"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1797 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.574442"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1797], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.574442"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1797 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.578736"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1797], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.578736"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1797 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.6ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.584787"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1797], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.584787"]]  (0.6ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1797 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 195ms  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.9ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:29.819316"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:29.819316"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1798 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.835131"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1798], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.835131"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1798 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.845943"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1798], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.845943"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1798 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.857590"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1798], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.857590"]]  (1.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"2157"} NotifyUser::BaseNotification Load (0.9ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1798 AND "notify_user_notifications"."target_type" = 'User' AND (id = '2157') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.6ms) SAVEPOINT active_record_1 User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1798]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1798 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2157 [["state", "read"], ["updated_at", "2015-09-28 03:44:29.886282"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 20ms (Views: 1.7ms | ActiveRecord: 2.7ms) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 2157 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:29.899880"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:29.899880"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1799 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.907072"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1799], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.907072"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1799 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.911140"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1799], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.911140"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1799 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.915467"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1799], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.915467"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"2160"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1799 AND "notify_user_notifications"."target_type" = 'User' AND (id = '2160') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.3ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1799]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1799 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2160 [["state", "read"], ["updated_at", "2015-09-28 03:44:29.925589"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.3ms | ActiveRecord: 1.8ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"2160"} NotifyUser::BaseNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1799 AND "notify_user_notifications"."target_type" = 'User' AND (id = '2160') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 3ms (Views: 0.2ms | ActiveRecord: 2.5ms)  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:29.937554"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:29.937554"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1800 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.944178"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1800], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.944178"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1800 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.949912"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1800], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.949912"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1800 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:29.954354"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1800], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:29.954354"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1800 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1800 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 4ms (Views: 0.9ms | ActiveRecord: 1.1ms) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1800 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:29.969703"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:29.969703"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 5ms (Views: 3.1ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:29.990088"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:29.990088"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 5ms (Views: 3.1ms | ActiveRecord: 0.0ms)  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.008892"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.008892"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1803 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.0ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:30.023578"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1803], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.023578"]]  (0.7ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["2166"]} SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1803 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2166')) NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1803 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2166')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.053271"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.053271"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1804 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:30.061836"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1804], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.061836"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["2167"]} SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1804 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2167')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1804 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2167')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.080743"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.080743"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1805 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:30.091142"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1805], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.091142"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1805 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.6ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1805 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1805) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:30.129631"], ["target_id", 1805], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.129631"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1805 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 39ms (Views: 2.3ms | ActiveRecord: 2.1ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1805 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.144947"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.144947"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1806 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:30.155023"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1806], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.155023"]]  (1.0ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1806 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1806 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1806 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 36ms (Views: 3.1ms | ActiveRecord: 0.9ms) NotifyUser::Unsubscribe Load (0.7ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1806 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.206489"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.206489"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1807 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:30.212497"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1807], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.212497"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1807 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1807) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:30.221132"], ["target_id", 1807], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.221132"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1807 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 8ms (ActiveRecord: 1.6ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.231708"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.231708"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1808 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:30.239874"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1808], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.239874"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1808) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:30.243187"], ["target_id", 1808], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.243187"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1808 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 378]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 5ms (ActiveRecord: 1.1ms) NotifyUser::Unsubscribe Load (0.2ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.258107"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.258107"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1809 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:30.265759"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1809], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.265759"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1809 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '2nP_lnxd-modDQfsbnKBmgvBK_634C7ie6Z8TiRBLZYg' LIMIT 1 SQL (0.5ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.277074"], ["target_id", 1809], ["target_type", "User"], ["token", "2nP_lnxd-modDQfsbnKBmgvBK_634C7ie6Z8TiRBLZYg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.277074"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"2nP_lnxd-modDQfsbnKBmgvBK_634C7ie6Z8TiRBLZYg"} NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '2nP_lnxd-modDQfsbnKBmgvBK_634C7ie6Z8TiRBLZYg' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '2nP_lnxd-modDQfsbnKBmgvBK_634C7ie6Z8TiRBLZYg' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1809]]  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1809) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:30.288751"], ["target_id", 1809], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.288751"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 223 [["active", "f"], ["updated_at", "2015-09-28 03:44:30.290675"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 10ms (Views: 0.4ms | ActiveRecord: 2.4ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.296412"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.296412"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1810 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.301484"], ["state", "pending"], ["target_id", 1810], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.301484"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1810 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1810 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.312731"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.312731"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1811 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.316668"], ["state", "pending"], ["target_id", 1811], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.316668"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1811 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1811 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.327750"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.327750"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1812 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.331834"], ["state", "pending"], ["target_id", 1812], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.331834"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1812 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.341738"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.341738"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1813 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.345808"], ["state", "pending"], ["target_id", 1813], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.345808"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1813 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.6ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 24.6ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.0ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.2ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.651416"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.651416"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1814 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.655856"], ["state", "pending"], ["target_id", 1814], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.655856"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1814 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.7ms) ROLLBACK  (0.4ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.8ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.672193"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.672193"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1815 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.678382"], ["state", "pending"], ["target_id", 1815], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.678382"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1815 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.685859"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.685859"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1816 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.689388"], ["state", "pending"], ["target_id", 1816], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.689388"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1816 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.697365"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.697365"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.701019"], ["state", "pending"], ["target_id", 1817], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.701019"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1817 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.707256"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.707256"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1818 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.710421"], ["state", "pending"], ["target_id", 1818], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.710421"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1818 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.715950"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.715950"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1819 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.719480"], ["state", "pending"], ["target_id", 1819], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.719480"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.723504"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.723504"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1820 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.727738"], ["state", "pending"], ["target_id", 1820], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.727738"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.731710"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.731710"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1821 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.735174"], ["state", "pending"], ["target_id", 1821], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.735174"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1821 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2184 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:44:30.738016"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.743278"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.743278"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1822 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.746813"], ["state", "pending"], ["target_id", 1822], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.746813"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1822 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2185 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:44:30.750185"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.755530"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.755530"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1823 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.759667"], ["state", "pending"], ["target_id", 1823], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.759667"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1823 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2186 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:44:30.763084"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (1.0ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.6ms) ROLLBACK  (0.4ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.775808"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.775808"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1824 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.783130"], ["state", "pending"], ["target_id", 1824], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.783130"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1824 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2187 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:44:30.785910"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.791589"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.791589"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1825 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.795237"], ["state", "pending"], ["target_id", 1825], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.795237"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1825 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2188]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.805373"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.805373"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1826 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.809680"], ["state", "pending"], ["target_id", 1826], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.809680"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1826 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1826 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.8ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2189 [["state", "sent"], ["updated_at", "2015-09-28 03:44:30.815554"]]  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1826 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.7ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2189 [["sent_time", "2015-09-28 03:44:30.818743"], ["updated_at", "2015-09-28 03:44:30.822978"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2189]]  (0.4ms) ROLLBACK  (0.3ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.834481"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.834481"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1827 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.837500"], ["state", "pending"], ["target_id", 1827], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.837500"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.841789"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.841789"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1828 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.845225"], ["state", "pending"], ["target_id", 1828], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.845225"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1828 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1828 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2191)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1828 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2191 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:30.851089"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2191]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1828]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1828 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1828]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1828 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2191 [["sent_time", "2015-09-28 03:44:30.857598"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:30.860194"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1828 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2191]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1828]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1828 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1828 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1828 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'FTEuoK6IjqQW9j1lsQJJOQrYa0DnGStVglXQ5qmDnoYg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.871287"], ["target_id", 1828], ["target_type", "User"], ["token", "FTEuoK6IjqQW9j1lsQJJOQrYa0DnGStVglXQ5qmDnoYg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.871287"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.4ms Sent mail to user@example.com (4.7ms) Date: Mon, 28 Sep 2015 13:44:30 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b79ed5fa3_111423fde7205e200864e4@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.881941"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.881941"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1829 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.885799"], ["state", "pending_as_aggregation_parent"], ["target_id", 1829], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.885799"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1829 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.889644"], ["state", "pending"], ["target_id", 1829], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.889644"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1829 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1829 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2193)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.896975"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.896975"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1830 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.900678"], ["state", "pending"], ["target_id", 1830], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.900678"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1830 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1830 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2194 [["state", "sent"], ["updated_at", "2015-09-28 03:44:30.905406"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1830 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2194 [["sent_time", "2015-09-28 03:44:30.906755"], ["updated_at", "2015-09-28 03:44:30.908632"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2194]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1830]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1830 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1830 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (1.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1830 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.5ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.9ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'zUTi10-bYOBibUd8gN9qEQr_iSQatpfPYyPyM7GdIjBw' LIMIT 1 SQL (0.6ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.922560"], ["target_id", 1830], ["target_type", "User"], ["token", "zUTi10-bYOBibUd8gN9qEQr_iSQatpfPYyPyM7GdIjBw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.922560"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 14.6ms Sent mail to user@example.com (4.2ms) Date: Mon, 28 Sep 2015 13:44:30 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b79ee3899_111423fde7205e20086583@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.937348"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.937348"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1831 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.940516"], ["state", "pending"], ["target_id", 1831], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.940516"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1831 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2195 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 03:44:30.943639"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.948310"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.948310"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1832 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.951592"], ["state", "pending"], ["target_id", 1832], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.951592"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1832) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:30.955581"], ["target_id", 1832], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:44:30.955581"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2196]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1832]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1832 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1832 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (4.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.969434"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.969434"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.9ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1833 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:30.981229"], ["state", "pending"], ["target_id", 1833], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:30.981229"]]  (1.4ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2197]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1833]]  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1833 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1833 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:30.997219"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:30.997219"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1834 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.002379"], ["state", "pending"], ["target_id", 1834], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.002379"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1834 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1834 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2198 [["state", "sent"], ["updated_at", "2015-09-28 03:44:31.009399"]]  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1834 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2198 [["sent_time", "2015-09-28 03:44:31.011341"], ["updated_at", "2015-09-28 03:44:31.013987"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2198]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1834]]  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1834 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1834 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1834 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'rZC8ktp_0mCH_8GJMq5KfQ1aALau5apimv8rBxF5Y15w' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.028350"], ["target_id", 1834], ["target_type", "User"], ["token", "rZC8ktp_0mCH_8GJMq5KfQ1aALau5apimv8rBxF5Y15w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.028350"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 9.6ms Sent mail to user@example.com (2.9ms) Date: Mon, 28 Sep 2015 13:44:31 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b79f8799_111423fde7205e20086661@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.041322"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.041322"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1835 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.045721"], ["state", "pending"], ["target_id", 1835], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.045721"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2199]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1835]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1835 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1835 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.054199"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.054199"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1836 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.057557"], ["state", "pending"], ["target_id", 1836], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.057557"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2200]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1836]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1836 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1836]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1836 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2200 [["sent_time", "2015-09-28 03:44:31.062157"], ["state", "sent"], ["updated_at", "2015-09-28 03:44:31.064508"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1836 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.071133"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.071133"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1837 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.075552"], ["state", "pending"], ["target_id", 1837], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.075552"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1837 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.079658"], ["state", "pending"], ["target_id", 1837], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.079658"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2202]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1837]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1837 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1837]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1837 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2202 [["sent_time", "2015-09-28 03:44:31.084915"], ["state", "sent"], ["updated_at", "2015-09-28 03:44:31.087549"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1837]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1837 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2201 [["sent_time", "2015-09-28 03:44:31.089480"], ["state", "sent"], ["updated_at", "2015-09-28 03:44:31.092108"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1837 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1837 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.100434"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.100434"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1838 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.104217"], ["state", "read"], ["target_id", 1838], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.104217"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2203]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1838]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1838 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.111835"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.111835"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1839 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1839 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.116450"], ["group_id", 2], ["state", "pending"], ["target_id", 1839], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.116450"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2204]] User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1839]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1839 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1839]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1839 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1839 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2204 [["sent_time", "2015-09-28 03:44:31.121950"], ["state", "sent"], ["updated_at", "2015-09-28 03:44:31.125756"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1839 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1839 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2204]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1839]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1839 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1839 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1839 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1839 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.3ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'cVg_9q4j9TYkLoFGSD0ZughnYjWxzA3cI3e98ld-VKtQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.140605"], ["target_id", 1839], ["target_type", "User"], ["token", "cVg_9q4j9TYkLoFGSD0ZughnYjWxzA3cI3e98ld-VKtQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.140605"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 7.6ms Sent mail to user@example.com (1.6ms) Date: Mon, 28 Sep 2015 13:44:31 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b79f238e8_111423fde7205e2008675d@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.149518"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.149518"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1840 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1840 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.154114"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1840], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.154114"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1840 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1840 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2205 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.158496"]]  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1840 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1840 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.7ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2205 [["sent_time", "2015-09-28 03:44:31.160366"], ["updated_at", "2015-09-28 03:44:31.168228"]]  (0.4ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2205]]  (0.4ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.179740"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.179740"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1841 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1841 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.184437"], ["group_id", 1], ["state", "pending"], ["target_id", 1841], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.184437"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1841 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2206) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.191415"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.191415"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1842 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1842 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.196254"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1842], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.196254"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1842 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1842 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.201122"], ["group_id", 1], ["state", "pending"], ["target_id", 1842], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.201122"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1842 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2208) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.207755"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.207755"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1843 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1843 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.212770"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1843], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.212770"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1843 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (2.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1843 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.8ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.234396"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1843], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.234396"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1843 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1843 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.244842"], ["group_id", 1], ["state", "pending"], ["target_id", 1843], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.244842"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1843 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2211) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.250964"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.250964"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1844 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1844 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.255775"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 1844], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.255775"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1844 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1844 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.260813"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 1844], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.260813"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1844 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1844 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.265387"], ["group_id", 1], ["state", "pending"], ["target_id", 1844], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.265387"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1844 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2214) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.271694"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.271694"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1845 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1845 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.276658"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1845], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.276658"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1845 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1845 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.281269"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1845], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.281269"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1845 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1845 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.286689"], ["group_id", 1], ["state", "pending"], ["target_id", 1845], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.286689"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1845 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2217) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.293422"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.293422"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1846 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1846 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 17:44:31.294705"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1846], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.298382"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1846 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:44:31.300754') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1846 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:44:31.300754') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1846 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1846 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:44:31.306735"], ["group_id", 1], ["parent_id", 2218], ["state", "pending"], ["target_id", 1846], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.306735"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.311164"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.311164"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1847 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1847 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:44:31.312331"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1847], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.315748"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1847 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:44:31.317854')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1847 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1847 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.322159"], ["group_id", 1], ["state", "pending"], ["target_id", 1847], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.322159"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.327726"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.327726"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1848 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1848 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:44:31.328990"], ["group_id", 1], ["state", "pending"], ["target_id", 1848], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.333919"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1848 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:44:31.336464')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1848 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1848 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.340891"], ["group_id", 1], ["state", "pending"], ["target_id", 1848], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.340891"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.5ms) ROLLBACK  (0.3ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.352334"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.352334"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1849 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1849 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.361777"], ["group_id", 1], ["state", "pending"], ["target_id", 1849], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.361777"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1849 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2224) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.9ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1849 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2224) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.370613"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.370613"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1850 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1850 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.9ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.378701"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1850], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.378701"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1850 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1850 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2225 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.392087"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1850 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1850 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2225 [["sent_time", "2015-09-28 03:44:31.394117"], ["updated_at", "2015-09-28 03:44:31.397091"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1850 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1850 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.402451"], ["group_id", 1], ["state", "pending"], ["target_id", 1850], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.402451"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1850 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2226) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1850 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2226) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.411421"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.411421"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.416400"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1851], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.416400"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2227 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.421913"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2227 [["sent_time", "2015-09-28 03:44:31.423253"], ["updated_at", "2015-09-28 03:44:31.426562"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.431942"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1851], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.431942"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2228 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.436374"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2228 [["sent_time", "2015-09-28 03:44:31.437778"], ["updated_at", "2015-09-28 03:44:31.440710"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1851 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.445949"], ["group_id", 1], ["state", "pending"], ["target_id", 1851], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.445949"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1851 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2229) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1851 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2229) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.4ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.456304"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.456304"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.461641"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1852], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.461641"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2230 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.465809"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2230 [["sent_time", "2015-09-28 03:44:31.467011"], ["updated_at", "2015-09-28 03:44:31.469442"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.473715"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1852], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.473715"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2231 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.477701"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2231 [["sent_time", "2015-09-28 03:44:31.478902"], ["updated_at", "2015-09-28 03:44:31.481431"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.485930"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1852], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.485930"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2232 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.490496"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2232 [["sent_time", "2015-09-28 03:44:31.492590"], ["updated_at", "2015-09-28 03:44:31.495359"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.500204"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1852], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.500204"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2233 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.504077"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2233 [["sent_time", "2015-09-28 03:44:31.505228"], ["updated_at", "2015-09-28 03:44:31.507768"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.512123"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1852], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.512123"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2234 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.516354"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2234 [["sent_time", "2015-09-28 03:44:31.517481"], ["updated_at", "2015-09-28 03:44:31.519886"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.524362"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1852], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.524362"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2235 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.528774"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2235 [["sent_time", "2015-09-28 03:44:31.530067"], ["updated_at", "2015-09-28 03:44:31.532383"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.537009"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1852], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.537009"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2236 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.541010"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2236 [["sent_time", "2015-09-28 03:44:31.542146"], ["updated_at", "2015-09-28 03:44:31.544568"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.549209"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1852], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.549209"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2237 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.553059"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2237 [["sent_time", "2015-09-28 03:44:31.554177"], ["updated_at", "2015-09-28 03:44:31.556707"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.561488"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1852], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.561488"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2238 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.565505"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2238 [["sent_time", "2015-09-28 03:44:31.566644"], ["updated_at", "2015-09-28 03:44:31.569189"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.574920"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1852], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.574920"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2239 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.580338"]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2239 [["sent_time", "2015-09-28 03:44:31.582019"], ["updated_at", "2015-09-28 03:44:31.585199"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.589923"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1852], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.589923"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.0ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2240 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.597694"]]  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2240 [["sent_time", "2015-09-28 03:44:31.602985"], ["updated_at", "2015-09-28 03:44:31.610279"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1852 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.615427"], ["group_id", 1], ["state", "pending"], ["target_id", 1852], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.615427"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1852 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2241) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1852 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2241) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.624599"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.624599"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1853 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1853 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.630366"], ["group_id", 1], ["state", "pending"], ["target_id", 1853], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.630366"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1853 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1853 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1853 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2242)  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1853 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1853 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2242 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.640684"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.4ms) ROLLBACK  (0.4ms) BEGIN  (0.6ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.657931"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.657931"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1854 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1854 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.664052"], ["group_id", 1], ["state", "pending"], ["target_id", 1854], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.664052"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1854 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1854 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1854 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2243)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1854 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1854 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2243 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.673648"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.678603"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.678603"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1855 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1855 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.683046"], ["group_id", 1], ["state", "pending"], ["target_id", 1855], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.683046"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1855 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1855 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1855 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2244)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1855 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1855 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2244 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.691092"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2244]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.697140"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.697140"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1856 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1856 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.702019"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1856], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.702019"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1856 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1856 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:31.702019"], ["group_id", 1], ["state", "pending"], ["target_id", 1856], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.706548"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1856 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1856 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1856 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2246)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1856 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1856 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2246 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:44:31.715280"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.720649"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.720649"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1857 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1857 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.725349"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1857], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.725349"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1857 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:44:31.727439') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1857 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:44:31.727439') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1857 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1857 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:46:31.725349"], ["group_id", 1], ["parent_id", 2247], ["state", "pending"], ["target_id", 1857], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.732648"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2248]]  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.737728"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.737728"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1858 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1858 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.741920"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1858], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.741920"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1858 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1858 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.746070"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1858], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.746070"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1858 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1858 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.751150"], ["group_id", 1], ["state", "pending"], ["target_id", 1858], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.751150"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1858 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1858 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1858 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2251)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.760348"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.760348"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1859 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1859 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.764791"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1859], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.764791"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1859 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1859 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.769317"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1859], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.769317"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1859 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1859 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:31.773483"], ["group_id", 1], ["state", "pending"], ["target_id", 1859], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.773483"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1859 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1859 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1859 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2254) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2254]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.782398"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.782398"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1860 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.788379"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.788379"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1861 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1861 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.795436"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.795436"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1862 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.801709"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.801709"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1863 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.805107"], ["state", "pending"], ["target_id", 1863], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.805107"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1863) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:31.808325"], ["target_id", 1863], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.808325"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1863 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.813225"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.813225"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1864 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.816438"], ["state", "pending"], ["target_id", 1864], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.816438"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1864 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.821688"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.821688"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1865 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.824723"], ["state", "pending"], ["target_id", 1865], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.824723"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1865) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:31.827787"], ["target_id", 1865], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:44:31.827787"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1865 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1865 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.833753"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.833753"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1866 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.837224"], ["state", "pending"], ["target_id", 1866], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.837224"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1866 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1866 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.844218"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.844218"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1867 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.847414"], ["state", "pending"], ["target_id", 1867], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.847414"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1867) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.850442"], ["group_id", 1], ["target_id", 1867], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.850442"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1867 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1867 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.857401"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.857401"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1868 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.860889"], ["state", "pending"], ["target_id", 1868], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.860889"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1868) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:31.863828"], ["target_id", 1868], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.863828"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1868 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1868 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.871199"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.871199"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.874483"], ["state", "pending"], ["target_id", 1869], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.874483"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2261 [["group_id", 1], ["updated_at", "2015-09-28 03:44:31.879436"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1869 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.887670"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.887670"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.890874"], ["state", "pending"], ["target_id", 1870], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.890874"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2262]] User Load (0.5ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1870]]  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1870 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.5ms) ROLLBACK  (0.3ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.908769"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.908769"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1871 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.913121"], ["state", "pending"], ["target_id", 1871], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.913121"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1871) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:31.916151"], ["target_id", 1871], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:44:31.916151"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2263]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1871]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1871 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1871 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.925178"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.925178"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1872 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.928833"], ["state", "pending"], ["target_id", 1872], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.928833"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1872) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.931822"], ["group_id", 1], ["target_id", 1872], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.931822"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1872 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2264]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1872]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1872 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.940477"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.940477"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1873 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.943900"], ["state", "pending"], ["target_id", 1873], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.943900"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1873 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1873 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.950069"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.950069"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1874 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.953245"], ["state", "pending"], ["target_id", 1874], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.953245"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1874) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:31.956148"], ["target_id", 1874], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:44:31.956148"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1874 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1874 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.962425"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.962425"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1875 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.966454"], ["state", "pending"], ["target_id", 1875], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.966454"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1875) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.969358"], ["group_id", 1], ["target_id", 1875], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.969358"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1875 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1875 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.977780"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.977780"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1876 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.983901"], ["state", "pending"], ["target_id", 1876], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.983901"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1876 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '9v3SY4InoeTzlpoJy5254wfwEwiPANhosUbzUZXC_i4w' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.987576"], ["target_id", 1876], ["target_type", "User"], ["token", "9v3SY4InoeTzlpoJy5254wfwEwiPANhosUbzUZXC_i4w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.987576"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:31.992623"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:31.992623"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1877 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:31.996506"], ["state", "pending"], ["target_id", 1877], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:31.996506"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1877 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'vkAeIGux05g9778d8yWVRwSa-mArj-eawC-4_YFjYwgQ' LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:32.000367"], ["target_id", 1877], ["target_type", "User"], ["token", "vkAeIGux05g9778d8yWVRwSa-mArj-eawC-4_YFjYwgQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.000367"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1877 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.007885"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:32.007885"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1878 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.9ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:32.013242"], ["state", "pending"], ["target_id", 1878], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.013242"]]  (1.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.9ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1878 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.3ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.7ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'SPgQ-NiDfPFvPJVoato6sQWG6rMFCOnVZPhmmAcaPDRA' LIMIT 1 SQL (0.5ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:32.023626"], ["target_id", 1878], ["target_type", "User"], ["token", "SPgQ-NiDfPFvPJVoato6sQWG6rMFCOnVZPhmmAcaPDRA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.023626"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 230 [["active", "f"], ["updated_at", "2015-09-28 03:44:32.028469"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1878 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'lH1H3-2LGm5jQ8YIIEaBeQwEZT5c1ZGD-recv42wFcSA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:32.031580"], ["target_id", 1878], ["target_type", "User"], ["token", "lH1H3-2LGm5jQ8YIIEaBeQwEZT5c1ZGD-recv42wFcSA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.031580"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.036537"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:32.036537"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1879 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1879) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:32.040331"], ["target_id", 1879], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.040331"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.043878"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:32.043878"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1880 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1880) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:32.047511"], ["target_id", 1880], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.047511"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1880 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.052945"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:32.052945"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1881) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:32.055779"], ["target_id", 1881], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.055779"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.7ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1881 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 391]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.062755"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:32.062755"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1882) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:32.065552"], ["target_id", 1882], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-28 03:44:32.065552"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1882 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.070715"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:32.070715"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1883) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:32.073305"], ["group_id", 1], ["target_id", 1883], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.073305"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1883 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 393]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.079654"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:32.079654"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1884) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:32.082338"], ["group_id", 1], ["target_id", 1884], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.082338"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1884 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.087509"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:32.087509"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1885) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:32.090238"], ["target_id", 1885], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.090238"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1885 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.095169"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:32.095169"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1886) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:32.098606"], ["target_id", 1886], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.098606"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1886 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.104420"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:32.104420"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1887) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:44:32.107323"], ["target_id", 1887], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.107323"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1887) LIMIT 1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1887 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1887 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 397]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1887 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.118753"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:32.118753"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1888 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.123927"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:32.123927"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'VYgh4ZFtJJ2cx4zdfYkyNwiHCYIvaGFvz_CjYDIsu1oA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:32.125977"], ["target_id", 1889], ["target_type", "User"], ["token", "VYgh4ZFtJJ2cx4zdfYkyNwiHCYIvaGFvz_CjYDIsu1oA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.125977"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'VYgh4ZFtJJ2cx4zdfYkyNwiHCYIvaGFvz_CjYDIsu1oA' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.131993"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:32.131993"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (1.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Ent-T32mqXpeZoG36sAmJQtJ67Q05F883ZcuP4s-Ijvg' LIMIT 1 SQL (0.9ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:32.135723"], ["target_id", 1890], ["target_type", "User"], ["token", "Ent-T32mqXpeZoG36sAmJQtJ67Q05F883ZcuP4s-Ijvg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.135723"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 233 [["active", "f"], ["updated_at", "2015-09-28 03:44:32.149257"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Ent-T32mqXpeZoG36sAmJQtJ67Q05F883ZcuP4s-Ijvg' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.154133"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:32.154133"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'UZkI1u_W2nlFSolzS89nywtw1aI0eWJI8fxc5f1Dg8kA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:32.156474"], ["target_id", 1891], ["target_type", "User"], ["token", "UZkI1u_W2nlFSolzS89nywtw1aI0eWJI8fxc5f1Dg8kA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.156474"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 234 [["active", "f"], ["updated_at", "2015-09-28 03:44:32.160886"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.163947"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:44:32.163947"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'kxG6UZBEGRdl_QxAYBjvWg8aAdNvTEJgUiohVyi9lPPQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:44:32.166003"], ["target_id", 1892], ["target_type", "User"], ["token", "kxG6UZBEGRdl_QxAYBjvWg8aAdNvTEJgUiohVyi9lPPQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.166003"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.172071"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-28 03:44:32.172071"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1893 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:32.175502"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1893], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.175502"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:44:32.180671"], ["email", "2@notifyuser.com"], ["updated_at", "2015-09-28 03:44:32.180671"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1894 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:44:32.183883"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1894], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:44:32.183883"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (1.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.232616"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.232616"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML Rendered /Users/anton/workspace/notify_user/app/views/notify_user/base_notifications/index.html.erb within layouts/application (0.3ms) Completed 200 OK in 22ms (Views: 17.6ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.271727"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.271727"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1896 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.298556"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1896], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.298556"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1896 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1896 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 14ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.320943"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.320943"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1897 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.327651"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1897], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.327651"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1897 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1897 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 5ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.341311"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.341311"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1898 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.347471"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1898], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.347471"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1898 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.350875"], ["parent_id", 1], ["state", "pending"], ["target_id", 1898], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.350875"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as JSON  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1898 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) NotifyUser::BaseNotification Load (0.9ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1898 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.365614"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.365614"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1899 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.371547"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1899], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.371547"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1899 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.375169"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1899], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.375169"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1899 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.378395"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1899], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.378395"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#index as HTML NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1899 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) ORDER BY created_at DESC LIMIT 25 OFFSET 0 Completed 500 Internal Server Error in 160ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.550365"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.550365"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1900 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.557630"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1900], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.557630"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1900 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.566899"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1900], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.566899"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1900 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.570670"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1900], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.570670"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"2280"} NotifyUser::BaseNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1900 AND "notify_user_notifications"."target_type" = 'User' AND (id = '2280') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1900]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1900 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2280 [["state", "read"], ["updated_at", "2015-09-28 03:46:27.584366"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 15ms (Views: 1.8ms | ActiveRecord: 1.8ms) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = 2280 ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.598443"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.598443"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1901 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.605279"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1901], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.605279"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1901 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.609172"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1901], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.609172"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1901 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.612651"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1901], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.612651"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"2283"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1901 AND "notify_user_notifications"."target_type" = 'User' AND (id = '2283') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1901]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1901 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2283 [["state", "read"], ["updated_at", "2015-09-28 03:46:27.622075"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 8ms (Views: 0.3ms | ActiveRecord: 1.7ms) Processing by NotifyUser::NotificationsController#read as HTML Parameters: {"id"=>"2283"} NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1901 AND "notify_user_notifications"."target_type" = 'User' AND (id = '2283') ORDER BY "notify_user_notifications"."id" ASC LIMIT 1 Completed 200 OK in 2ms (Views: 0.2ms | ActiveRecord: 2.1ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.632559"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.632559"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1902 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.638457"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1902], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.638457"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1902 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.642710"], ["params", "{\"name\":\"Mr. Adams\"}"], ["state", "pending"], ["target_id", 1902], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.642710"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1902 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.646182"], ["params", "{\"name\":\"Mrs. James\"}"], ["state", "pending"], ["target_id", 1902], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.646182"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_all as HTML SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1902 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1902 AND "notify_user_notifications"."target_type" = 'User' AND (state != 'read') Completed 200 OK in 3ms (Views: 0.8ms | ActiveRecord: 0.9ms) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1902 AND "notify_user_notifications"."target_type" = 'User' AND (state IN ('["pending","sent"]'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.659814"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.659814"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>true}} Completed 201 Created in 3ms (Views: 1.8ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.678350"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.678350"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe_from_object as JSON Parameters: {"subscription"=>{"type"=>"NewPostNotification", "group_id"=>1, "unsubscribe"=>false}} Completed 201 Created in 3ms (Views: 1.8ms | ActiveRecord: 0.0ms)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.693936"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.693936"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1905 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.701198"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1905], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.701198"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["2289"]} SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1905 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2289')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1905 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2289')) Completed 500 Internal Server Error in 6ms  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.718481"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.718481"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1906 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.726188"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1906], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.726188"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#mark_read as HTML Parameters: {"ids"=>["2290"]} SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = 'read' WHERE "notify_user_notifications"."target_id" = 1906 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2290')) NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1906 AND "notify_user_notifications"."target_type" = 'User' AND (id IN ('2290')) Completed 500 Internal Server Error in 6ms  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.744700"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.744700"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1907 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.752663"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1907], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.752663"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1907 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"0"}]} NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1907 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1907) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:27.776759"], ["target_id", 1907], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.776759"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1907 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 24ms (Views: 2.2ms | ActiveRecord: 1.7ms) NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1907 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.789167"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.789167"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1908 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.796510"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1908], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.796510"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Load (0.9ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1908 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL Processing by NotifyUser::NotificationsController#subscriptions as HTML Parameters: {"types"=>[{"type"=>"NewPostNotification", "status"=>"1"}]} NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1908 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1908 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 200 OK in 17ms (Views: 1.6ms | ActiveRecord: 0.9ms) NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1908 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.827517"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.827517"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1909 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.833854"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1909], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.833854"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unsubscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1909 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.6ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1909) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:27.842456"], ["target_id", 1909], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.842456"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1909 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' Completed 302 Found in 9ms (ActiveRecord: 1.9ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" ORDER BY "notify_user_unsubscribes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.853071"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.853071"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1910 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.860121"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1910], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.860121"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1910) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:27.863361"], ["target_id", 1910], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.863361"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#subscribe as HTML Parameters: {"type"=>"NewPostNotification"} NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1910 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 400]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/notify_user/notifications/unsubscribe Completed 302 Found in 4ms (ActiveRecord: 1.0ms) NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.876993"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.876993"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1911 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:27.883591"], ["params", "{\"name\":\"Mr. Blobby\"}"], ["state", "pending"], ["target_id", 1911], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.883591"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1911 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'LK-zNvCatr9Ow6DJqN6l-wWV3Tp9ppeSC8Eh0k1K4Y9A' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:27.895040"], ["target_id", 1911], ["target_type", "User"], ["token", "LK-zNvCatr9Ow6DJqN6l-wWV3Tp9ppeSC8Eh0k1K4Y9A"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.895040"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by NotifyUser::NotificationsController#unauth_unsubscribe as HTML Parameters: {"type"=>"NewPostNotification", "token"=>"LK-zNvCatr9Ow6DJqN6l-wWV3Tp9ppeSC8Eh0k1K4Y9A"} NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'LK-zNvCatr9Ow6DJqN6l-wWV3Tp9ppeSC8Eh0k1K4Y9A' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'LK-zNvCatr9Ow6DJqN6l-wWV3Tp9ppeSC8Eh0k1K4Y9A' AND "notify_user_user_hashes"."type" = 'NewPostNotification' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1911]]  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1911) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:27.905282"], ["target_id", 1911], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.905282"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 236 [["active", "f"], ["updated_at", "2015-09-28 03:46:27.907435"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Completed 200 OK in 10ms (Views: 0.4ms | ActiveRecord: 2.5ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" ORDER BY "notify_user_user_hashes"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.913829"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.913829"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1912 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:27.917655"], ["state", "pending"], ["target_id", 1912], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.917655"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1912 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1912 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.928102"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.928102"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1913 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:27.931703"], ["state", "pending"], ["target_id", 1913], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.931703"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1913 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1913 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.942134"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.942134"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1914 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:27.946092"], ["state", "pending"], ["target_id", 1914], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.946092"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1914 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:27.957320"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:27.957320"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1915 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:27.962559"], ["state", "pending"], ["target_id", 1915], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:27.962559"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1915 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 25.0ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.1ms NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 4.9ms NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" IS NULL AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.226176"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.226176"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1916 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.229818"], ["state", "pending"], ["target_id", 1916], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.229818"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1916 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.236191"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.236191"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1917 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.239962"], ["state", "pending"], ["target_id", 1917], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.239962"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1917 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.246910"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.246910"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1918 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.250615"], ["state", "pending"], ["target_id", 1918], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.250615"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1918 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.258314"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.258314"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1919 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.262353"], ["state", "pending"], ["target_id", 1919], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.262353"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1919 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.269018"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.269018"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1920 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.272554"], ["state", "pending"], ["target_id", 1920], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.272554"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1920 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.277888"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.277888"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1921 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.281160"], ["state", "pending"], ["target_id", 1921], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.281160"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.284882"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.284882"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1922 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.288197"], ["state", "pending"], ["target_id", 1922], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.288197"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.292695"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.292695"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1923 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.296146"], ["state", "pending"], ["target_id", 1923], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.296146"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1923 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2307 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:46:28.298964"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.304053"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.304053"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1924 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.307367"], ["state", "pending"], ["target_id", 1924], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.307367"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1924 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2308 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:46:28.310401"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.315789"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.315789"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1925 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.319165"], ["state", "pending"], ["target_id", 1925], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.319165"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1925 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2309 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:46:28.321963"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.326867"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.326867"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1926 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.330280"], ["state", "pending"], ["target_id", 1926], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.330280"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1926 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2310 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:46:28.333475"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.338869"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.338869"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1927 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.343083"], ["state", "pending"], ["target_id", 1927], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.343083"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1927 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2311]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.350224"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.350224"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1928 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.353667"], ["state", "pending"], ["target_id", 1928], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.353667"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1928 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1928 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2312 [["state", "sent"], ["updated_at", "2015-09-28 03:46:28.358269"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1928 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2312 [["sent_time", "2015-09-28 03:46:28.359431"], ["updated_at", "2015-09-28 03:46:28.360927"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2312]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.366183"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.366183"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1929 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.369591"], ["state", "pending"], ["target_id", 1929], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.369591"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1929 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2313]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.376766"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.376766"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1930 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.380354"], ["state", "pending"], ["target_id", 1930], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.380354"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1930 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1930 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2314)  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1930 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2314 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:28.386270"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2314]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1930]] NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1930 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1930]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1930 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2314 [["sent_time", "2015-09-28 03:46:28.393321"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:28.395985"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1930 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2314]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1930]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1930 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1930 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1930 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.5ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'UwQQdMqKFpH8_s54AfRCXQdHMg_O25L6Ocfn21kzPWnQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.406440"], ["target_id", 1930], ["target_type", "User"], ["token", "UwQQdMqKFpH8_s54AfRCXQdHMg_O25L6Ocfn21kzPWnQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.406440"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.0ms Sent mail to user@example.com (4.3ms) Date: Mon, 28 Sep 2015 13:46:28 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b814647f2_115bf3fd7d1854204732f4@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.417024"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.417024"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1931 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.420580"], ["state", "pending_as_aggregation_parent"], ["target_id", 1931], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.420580"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1931 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.424012"], ["state", "pending"], ["target_id", 1931], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.424012"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1931 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1931 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2316)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.430986"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.430986"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1932 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.434173"], ["state", "pending"], ["target_id", 1932], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.434173"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1932 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1932 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2317 [["state", "sent"], ["updated_at", "2015-09-28 03:46:28.438113"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1932 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2317 [["sent_time", "2015-09-28 03:46:28.439392"], ["updated_at", "2015-09-28 03:46:28.440873"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2317]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1932]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1932 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1932 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1932 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'izZiXJFWOT4U4AEo74Bs7gylm4_SiiHtZseLaiUW-wBg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.450505"], ["target_id", 1932], ["target_type", "User"], ["token", "izZiXJFWOT4U4AEo74Bs7gylm4_SiiHtZseLaiUW-wBg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.450505"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.9ms Sent mail to user@example.com (1.7ms) Date: Mon, 28 Sep 2015 13:46:28 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b8146ee85_115bf3fd7d18542047339a@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.458165"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.458165"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1933 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.462488"], ["state", "pending"], ["target_id", 1933], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.462488"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1933 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2318 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 03:46:28.465461"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.469546"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.469546"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1934 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.473281"], ["state", "pending"], ["target_id", 1934], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.473281"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1934) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:28.476422"], ["target_id", 1934], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:46:28.476422"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2319]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1934]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1934 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1934 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.484506"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.484506"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1935 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.487979"], ["state", "pending"], ["target_id", 1935], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.487979"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2320]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1935]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1935 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1935 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.496154"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.496154"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1936 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.499486"], ["state", "pending"], ["target_id", 1936], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.499486"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1936 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1936 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2321 [["state", "sent"], ["updated_at", "2015-09-28 03:46:28.503941"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1936 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2321 [["sent_time", "2015-09-28 03:46:28.505237"], ["updated_at", "2015-09-28 03:46:28.506638"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2321]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1936]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1936 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1936 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1936 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'M6O745E1HtnUIMBLgBwrhgXGJ5x4FwBXSF226zfJC9JQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.516112"], ["target_id", 1936], ["target_type", "User"], ["token", "M6O745E1HtnUIMBLgBwrhgXGJ5x4FwBXSF226zfJC9JQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.516112"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.7ms Sent mail to user@example.com (1.7ms) Date: Mon, 28 Sep 2015 13:46:28 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b8147eee1_115bf3fd7d1854204734f0@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.523751"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.523751"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1937 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.526999"], ["state", "pending"], ["target_id", 1937], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.526999"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2322]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1937]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1937 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1937 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.535221"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.535221"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1938 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.538759"], ["state", "pending"], ["target_id", 1938], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.538759"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2323]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1938]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1938 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.3ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1938]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1938 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2323 [["sent_time", "2015-09-28 03:46:28.544736"], ["state", "sent"], ["updated_at", "2015-09-28 03:46:28.547862"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1938 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.555052"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.555052"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1939 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.559204"], ["state", "pending"], ["target_id", 1939], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.559204"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1939 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.563363"], ["state", "pending"], ["target_id", 1939], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.563363"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2325]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1939]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1939 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1939]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1939 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2325 [["sent_time", "2015-09-28 03:46:28.567805"], ["state", "sent"], ["updated_at", "2015-09-28 03:46:28.570417"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1939]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1939 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2324 [["sent_time", "2015-09-28 03:46:28.572133"], ["state", "sent"], ["updated_at", "2015-09-28 03:46:28.574818"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1939 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1939 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.583102"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.583102"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1940 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.586741"], ["state", "read"], ["target_id", 1940], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.586741"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2326]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1940]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1940 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.596132"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.596132"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1941 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1941 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.600619"], ["group_id", 2], ["state", "pending"], ["target_id", 1941], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.600619"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2327]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1941]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1941 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1941]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1941 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1941 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2327 [["sent_time", "2015-09-28 03:46:28.605533"], ["state", "sent"], ["updated_at", "2015-09-28 03:46:28.610329"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1941 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1941 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2327]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1941]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1941 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1941 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1941 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1941 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'O9rgzy5flrtjJkDfBD7LWgYSh2Vt6kDQG7ioHCyFVvBg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:28.622777"], ["target_id", 1941], ["target_type", "User"], ["token", "O9rgzy5flrtjJkDfBD7LWgYSh2Vt6kDQG7ioHCyFVvBg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.622777"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.6ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 13:46:28 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b81498f0e_115bf3fd7d1854204735de@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.630305"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.630305"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1942 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1942 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.634750"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1942], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.634750"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1942 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1942 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2328 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:28.638831"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1942 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1942 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2328 [["sent_time", "2015-09-28 03:46:28.640002"], ["updated_at", "2015-09-28 03:46:28.643410"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2328]]  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.650824"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.650824"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1943 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1943 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.655183"], ["group_id", 1], ["state", "pending"], ["target_id", 1943], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.655183"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1943 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2329) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.661545"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.661545"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1944 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1944 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.667710"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1944], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.667710"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1944 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1944 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.674053"], ["group_id", 1], ["state", "pending"], ["target_id", 1944], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.674053"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1944 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2331) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.681314"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.681314"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1945 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1945 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.686303"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1945], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.686303"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1945 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1945 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.700410"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1945], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.700410"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1945 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1945 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.705342"], ["group_id", 1], ["state", "pending"], ["target_id", 1945], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.705342"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1945 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2334) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.713479"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.713479"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1946 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1946 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.717864"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 1946], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.717864"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1946 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1946 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.722394"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 1946], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.722394"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1946 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1946 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.726994"], ["group_id", 1], ["state", "pending"], ["target_id", 1946], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.726994"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1946 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2337) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.734037"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.734037"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1947 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1947 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.738834"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1947], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.738834"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1947 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1947 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.743642"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1947], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.743642"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1947 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1947 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.748659"], ["group_id", 1], ["state", "pending"], ["target_id", 1947], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.748659"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1947 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2340) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.756264"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.756264"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1948 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1948 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 17:46:28.757539"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1948], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.762651"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1948 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:46:28.764952') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1948 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:46:28.764952') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1948 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1948 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:46:28.770665"], ["group_id", 1], ["parent_id", 2341], ["state", "pending"], ["target_id", 1948], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.770665"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.775406"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.775406"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1949 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1949 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:46:28.776579"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1949], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.780564"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1949 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:46:28.782557')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1949 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1949 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.786867"], ["group_id", 1], ["state", "pending"], ["target_id", 1949], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.786867"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.791046"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.791046"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1950 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1950 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:46:28.792396"], ["group_id", 1], ["state", "pending"], ["target_id", 1950], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.796624"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1950 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:46:28.799061')  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1950 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1950 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.803539"], ["group_id", 1], ["state", "pending"], ["target_id", 1950], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.803539"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.809304"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.809304"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1951 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1951 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.815499"], ["group_id", 1], ["state", "pending"], ["target_id", 1951], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.815499"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1951 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2347) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1951 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2347) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.823691"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.823691"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1952 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1952 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.828209"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1952], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.828209"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1952 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1952 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2348 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:28.834128"]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1952 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1952 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2348 [["sent_time", "2015-09-28 03:46:28.836072"], ["updated_at", "2015-09-28 03:46:28.839961"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1952 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (6.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1952 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.851517"], ["group_id", 1], ["state", "pending"], ["target_id", 1952], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.851517"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1952 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2349) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (1.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1952 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2349) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.865796"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.865796"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1953 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1953 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.871510"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1953], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.871510"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1953 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1953 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2350 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:28.876794"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1953 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1953 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2350 [["sent_time", "2015-09-28 03:46:28.878024"], ["updated_at", "2015-09-28 03:46:28.880884"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1953 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1953 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.885738"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1953], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.885738"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1953 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1953 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2351 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:28.890281"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1953 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1953 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2351 [["sent_time", "2015-09-28 03:46:28.891557"], ["updated_at", "2015-09-28 03:46:28.894491"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1953 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1953 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.899540"], ["group_id", 1], ["state", "pending"], ["target_id", 1953], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.899540"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1953 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2352) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1953 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2352) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:28.906895"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:28.906895"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.912435"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1954], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.912435"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2353 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:28.917084"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2353 [["sent_time", "2015-09-28 03:46:28.918398"], ["updated_at", "2015-09-28 03:46:28.920895"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.925476"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1954], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.925476"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2354 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:28.929742"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2354 [["sent_time", "2015-09-28 03:46:28.930963"], ["updated_at", "2015-09-28 03:46:28.933603"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.938073"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1954], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.938073"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2355 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:28.942078"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2355 [["sent_time", "2015-09-28 03:46:28.943261"], ["updated_at", "2015-09-28 03:46:28.946018"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.950637"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1954], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.950637"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2356 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:28.954701"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2356 [["sent_time", "2015-09-28 03:46:28.955828"], ["updated_at", "2015-09-28 03:46:28.958624"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.963828"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1954], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.963828"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2357 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:28.967928"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2357 [["sent_time", "2015-09-28 03:46:28.969410"], ["updated_at", "2015-09-28 03:46:28.972485"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.977113"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1954], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.977113"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2358 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:28.981603"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2358 [["sent_time", "2015-09-28 03:46:28.982754"], ["updated_at", "2015-09-28 03:46:28.985228"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:28.989492"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1954], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:28.989492"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2359 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:28.993370"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2359 [["sent_time", "2015-09-28 03:46:28.994559"], ["updated_at", "2015-09-28 03:46:28.997100"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.001473"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1954], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.001473"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2360 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:29.005607"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2360 [["sent_time", "2015-09-28 03:46:29.006797"], ["updated_at", "2015-09-28 03:46:29.009311"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.013629"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1954], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.013629"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2361 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:29.017842"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2361 [["sent_time", "2015-09-28 03:46:29.019109"], ["updated_at", "2015-09-28 03:46:29.021730"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.026079"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1954], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.026079"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2362 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:29.030020"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2362 [["sent_time", "2015-09-28 03:46:29.031303"], ["updated_at", "2015-09-28 03:46:29.033766"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.038541"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1954], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.038541"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2363 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:29.042629"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2363 [["sent_time", "2015-09-28 03:46:29.043802"], ["updated_at", "2015-09-28 03:46:29.046507"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1954 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.051420"], ["group_id", 1], ["state", "pending"], ["target_id", 1954], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.051420"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1954 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2364) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1954 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2364) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.059474"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.059474"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1955 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1955 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.064032"], ["group_id", 1], ["state", "pending"], ["target_id", 1955], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.064032"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1955 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1955 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1955 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2365)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1955 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1955 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2365 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:29.075210"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.080511"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.080511"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1956 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1956 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.085045"], ["group_id", 1], ["state", "pending"], ["target_id", 1956], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.085045"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1956 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1956 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1956 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2366)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1956 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1956 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2366 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:29.093583"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.098608"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.098608"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1957 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1957 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.103385"], ["group_id", 1], ["state", "pending"], ["target_id", 1957], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.103385"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1957 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1957 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1957 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2367)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1957 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1957 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2367 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:29.112726"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2367]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.118743"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.118743"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1958 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1958 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.123149"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1958], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.123149"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1958 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1958 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:29.123149"], ["group_id", 1], ["state", "pending"], ["target_id", 1958], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.127476"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1958 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1958 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1958 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2369)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1958 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1958 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2369 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:46:29.135340"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.139809"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.139809"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1959 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1959 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.144277"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1959], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.144277"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1959 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:46:29.146634') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 1959 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:46:29.146634') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1959 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1959 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:48:29.144277"], ["group_id", 1], ["parent_id", 2370], ["state", "pending"], ["target_id", 1959], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.152051"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2371]]  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.157076"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.157076"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1960 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1960 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.162304"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1960], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.162304"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1960 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1960 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.167130"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1960], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.167130"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1960 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1960 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.171657"], ["group_id", 1], ["state", "pending"], ["target_id", 1960], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.171657"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1960 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1960 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1960 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2374)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.180406"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.180406"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1961 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1961 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.185025"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 1961], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.185025"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1961 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1961 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.189068"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 1961], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.189068"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1961 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1961 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.193312"], ["group_id", 1], ["state", "pending"], ["target_id", 1961], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.193312"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1961 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1961 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 1961 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2377) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2377]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.202397"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.202397"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1962 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.207966"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.207966"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1963 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1963 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.215153"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.215153"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1964 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.221046"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.221046"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1965 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.224137"], ["state", "pending"], ["target_id", 1965], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.224137"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1965) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:29.227227"], ["target_id", 1965], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.227227"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1965 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.232234"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.232234"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.235577"], ["state", "pending"], ["target_id", 1966], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.235577"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1966 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.240930"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.240930"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.244187"], ["state", "pending"], ["target_id", 1967], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.244187"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1967) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:29.247456"], ["target_id", 1967], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:46:29.247456"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1967 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.252954"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.252954"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1968 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.256083"], ["state", "pending"], ["target_id", 1968], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.256083"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1968 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1968 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.263014"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.263014"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1969 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.266279"], ["state", "pending"], ["target_id", 1969], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.266279"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1969) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.269149"], ["group_id", 1], ["target_id", 1969], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.269149"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1969 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1969 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.276206"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.276206"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1970 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.279584"], ["state", "pending"], ["target_id", 1970], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.279584"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1970) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:29.282337"], ["target_id", 1970], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.282337"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1970 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1970 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.289015"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.289015"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1971 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.292602"], ["state", "pending"], ["target_id", 1971], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.292602"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1971 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1971 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2384 [["group_id", 1], ["updated_at", "2015-09-28 03:46:29.296939"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1971 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1971 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.303698"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.303698"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1972 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.307107"], ["state", "pending"], ["target_id", 1972], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.307107"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2385]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1972]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1972 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1972 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.315907"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.315907"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1973 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.319222"], ["state", "pending"], ["target_id", 1973], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.319222"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1973) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:29.321964"], ["target_id", 1973], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:46:29.321964"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2386]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1973]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1973 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1973 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.330141"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.330141"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1974 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.333436"], ["state", "pending"], ["target_id", 1974], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.333436"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1974) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.336905"], ["group_id", 1], ["target_id", 1974], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.336905"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1974 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2387]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 1974]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1974 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.346044"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.346044"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1975 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.349268"], ["state", "pending"], ["target_id", 1975], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.349268"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1975 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1975 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.355658"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.355658"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1976 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.359447"], ["state", "pending"], ["target_id", 1976], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.359447"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1976) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:29.362532"], ["target_id", 1976], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:46:29.362532"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1976 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1976 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.368475"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.368475"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1977 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.371724"], ["state", "pending"], ["target_id", 1977], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.371724"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1977) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.374689"], ["group_id", 1], ["target_id", 1977], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.374689"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1977 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1977 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.381919"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.381919"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1978 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.385058"], ["state", "pending"], ["target_id", 1978], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.385058"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1978 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'uLBhAtyVu6BtzhIcGPjOHQGDeMYNttHSczRCyHThSFuA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.388250"], ["target_id", 1978], ["target_type", "User"], ["token", "uLBhAtyVu6BtzhIcGPjOHQGDeMYNttHSczRCyHThSFuA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.388250"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.392713"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.392713"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1979 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.396281"], ["state", "pending"], ["target_id", 1979], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.396281"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1979 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'PZiAPL8iOgKsKCJm_sQWEQP0L_y2SbnfuDG-H4BkxPlQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.399648"], ["target_id", 1979], ["target_type", "User"], ["token", "PZiAPL8iOgKsKCJm_sQWEQP0L_y2SbnfuDG-H4BkxPlQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.399648"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1979 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.405218"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.405218"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1980 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.408629"], ["state", "pending"], ["target_id", 1980], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.408629"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1980 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '5jX4En3_9Dq_TwILHc-megUIEpmExHHxe21dUAEIdbvQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.412782"], ["target_id", 1980], ["target_type", "User"], ["token", "5jX4En3_9Dq_TwILHc-megUIEpmExHHxe21dUAEIdbvQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.412782"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 243 [["active", "f"], ["updated_at", "2015-09-28 03:46:29.415167"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 1980 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'edFMxBOlwENbrQLsgKob0gpHiRQMvfYjrIR5k-9RMFWA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.418226"], ["target_id", 1980], ["target_type", "User"], ["token", "edFMxBOlwENbrQLsgKob0gpHiRQMvfYjrIR5k-9RMFWA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.418226"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.423041"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.423041"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1981 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1981) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:29.427410"], ["target_id", 1981], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.427410"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.430838"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.430838"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1982 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1982) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:29.434603"], ["target_id", 1982], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.434603"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1982 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL LIMIT 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.439675"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.439675"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1983) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:29.442623"], ["target_id", 1983], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.442623"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.4ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1983 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 413]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.449290"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.449290"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'AnotherPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1984) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:29.452006"], ["target_id", 1984], ["target_type", "User"], ["type", "AnotherPostNotification"], ["updated_at", "2015-09-28 03:46:29.452006"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1984 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.457186"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.457186"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1985) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.461090"], ["group_id", 1], ["target_id", 1985], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.461090"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1985 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 415]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.467409"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.467409"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1986) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.471236"], ["group_id", 1], ["target_id", 1986], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.471236"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" NotifyUser::Unsubscribe Load (0.5ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1986 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes"  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.480138"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.480138"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1987) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:29.484806"], ["target_id", 1987], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.484806"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1987 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.489775"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.489775"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1988) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:29.492482"], ["target_id", 1988], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.492482"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1988 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.498124"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.498124"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1989) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:46:29.501192"], ["target_id", 1989], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.501192"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 1989) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1989 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' NotifyUser::Unsubscribe Load (0.3ms) SELECT "notify_user_unsubscribes".* FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1989 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" IS NULL  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."id" = $1 [["id", 419]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1989 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.512485"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.512485"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1990 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.516999"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.516999"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'r7uoliIFpxdHNcbhbAm_gwlLhywLJtnaxQG4gg9XFdSw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.518849"], ["target_id", 1991], ["target_type", "User"], ["token", "r7uoliIFpxdHNcbhbAm_gwlLhywLJtnaxQG4gg9XFdSw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.518849"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'r7uoliIFpxdHNcbhbAm_gwlLhywLJtnaxQG4gg9XFdSw' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.524279"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.524279"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'S9VDSqkWzQSJrjDIKzDVjwo36jiM2jfDqpRhsoHWhn3Q' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.526316"], ["target_id", 1992], ["target_type", "User"], ["token", "S9VDSqkWzQSJrjDIKzDVjwo36jiM2jfDqpRhsoHWhn3Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.526316"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 246 [["active", "f"], ["updated_at", "2015-09-28 03:46:29.529500"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'S9VDSqkWzQSJrjDIKzDVjwo36jiM2jfDqpRhsoHWhn3Q' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.533382"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.533382"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'cZfyq3scIuMhRkQH193LKwMdIhjWQ8T-5ArJLniume5A' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.535275"], ["target_id", 1993], ["target_type", "User"], ["token", "cZfyq3scIuMhRkQH193LKwMdIhjWQ8T-5ArJLniume5A"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.535275"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 247 [["active", "f"], ["updated_at", "2015-09-28 03:46:29.538553"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.541929"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:46:29.541929"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'd2humxvQYPfrzWXeKLUK6AK_RUOaT8zkSzH95uTtPOuQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:46:29.544060"], ["target_id", 1994], ["target_type", "User"], ["token", "d2humxvQYPfrzWXeKLUK6AK_RUOaT8zkSzH95uTtPOuQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.544060"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.549929"], ["email", "1@notifyuser.com"], ["updated_at", "2015-09-28 03:46:29.549929"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1995 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.553066"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1995], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.553066"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:46:29.557529"], ["email", "2@notifyuser.com"], ["updated_at", "2015-09-28 03:46:29.557529"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1996 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "params", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:46:29.561353"], ["params", "{\"data\":\"My Data\"}"], ["state", "pending"], ["target_id", 1996], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:46:29.561353"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:22.462932"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:22.462932"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1997 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:22.492303"], ["state", "pending"], ["target_id", 1997], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:22.492303"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 1997 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:22.500189"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:22.500189"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1998 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:22.503824"], ["state", "pending"], ["target_id", 1998], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:22.503824"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:22.507783"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:22.507783"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 1999 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:22.511208"], ["state", "pending"], ["target_id", 1999], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:22.511208"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:22.515536"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:22.515536"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2000 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:22.518939"], ["state", "pending"], ["target_id", 2000], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:22.518939"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2000 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2399 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:48:22.522337"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:22.531195"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:22.531195"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2001 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:22.535115"], ["state", "pending"], ["target_id", 2001], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:22.535115"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2001 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2400 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:48:22.538311"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.9ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:22.545186"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:22.545186"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2002 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:22.548750"], ["state", "pending"], ["target_id", 2002], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:22.548750"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2002 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2401 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:48:22.551883"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:22.557290"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:22.557290"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2003 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:22.560592"], ["state", "pending"], ["target_id", 2003], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:22.560592"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2003 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2402 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:48:22.563736"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:22.568934"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:22.568934"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2004 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:22.572428"], ["state", "pending"], ["target_id", 2004], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:22.572428"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2004 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2403]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:22.579681"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:22.579681"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2005 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:22.583386"], ["state", "pending"], ["target_id", 2005], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:22.583386"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2005 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2005 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2404 [["state", "sent"], ["updated_at", "2015-09-28 03:48:22.589879"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2005 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2404 [["sent_time", "2015-09-28 03:48:22.591204"], ["updated_at", "2015-09-28 03:48:22.592804"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2404]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:22.598555"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:22.598555"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2006 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:22.601900"], ["state", "pending"], ["target_id", 2006], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:22.601900"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2006 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2405]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:22.609197"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:22.609197"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2007 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:22.612493"], ["state", "pending"], ["target_id", 2007], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:22.612493"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2007 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-27 02:48:22.613779"], ["state", "pending"], ["target_id", 2007], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:22.615786"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2007 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2406]]  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:34.493001"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:34.493001"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2008 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.496736"], ["state", "pending"], ["target_id", 2008], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.496736"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2008 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2008 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2408)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2008 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2408 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:34.503537"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2408]] User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2008]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2008 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2008]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2008 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2408 [["sent_time", "2015-09-28 03:48:34.514578"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:34.517961"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2008 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2408]] User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2008]]  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2008 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2008 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.3ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (2.8ms) NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2008 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'g0GsRijwF1MYyK1-0AJOCgIZo0ZocyA4EckIe0y0GuhA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.566809"], ["target_id", 2008], ["target_type", "User"], ["token", "g0GsRijwF1MYyK1-0AJOCgIZo0ZocyA4EckIe0y0GuhA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.566809"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 197.1ms Sent mail to user@example.com (5.7ms) Date: Mon, 28 Sep 2015 13:48:34 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b892b326c_11a343fd84906020066517@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:34.738957"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:34.738957"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2009 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.742716"], ["state", "pending_as_aggregation_parent"], ["target_id", 2009], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.742716"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2009 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.746322"], ["state", "pending"], ["target_id", 2009], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.746322"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2009 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2009 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2410)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:34.753250"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:34.753250"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2010 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.756889"], ["state", "pending"], ["target_id", 2010], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.756889"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2010 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2010 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2411 [["state", "sent"], ["updated_at", "2015-09-28 03:48:34.761102"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2010 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2411 [["sent_time", "2015-09-28 03:48:34.762327"], ["updated_at", "2015-09-28 03:48:34.763750"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2411]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2010]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2010 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2010 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.3ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2010 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'lx7T5XHNQHA6J_Mmt7K8gQOGQho913DFqTRfVZYzS-GQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.773269"], ["target_id", 2010], ["target_type", "User"], ["token", "lx7T5XHNQHA6J_Mmt7K8gQOGQho913DFqTRfVZYzS-GQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.773269"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.3ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 13:48:34 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b892bdb9a_11a343fd8490602006664a@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:34.781161"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:34.781161"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2011 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.786799"], ["state", "pending"], ["target_id", 2011], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.786799"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2011 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2412 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 03:48:34.790374"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:34.794459"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:34.794459"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2012 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.797667"], ["state", "pending"], ["target_id", 2012], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.797667"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2012) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:48:34.803482"], ["target_id", 2012], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:48:34.803482"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2413]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2012]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2012 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2012 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:34.812458"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:34.812458"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2013 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.815735"], ["state", "pending"], ["target_id", 2013], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.815735"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2414]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2013]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2013 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2013 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:34.824172"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:34.824172"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2014 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.827966"], ["state", "pending"], ["target_id", 2014], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.827966"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2014 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2014 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2415 [["state", "sent"], ["updated_at", "2015-09-28 03:48:34.832801"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2014 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2415 [["sent_time", "2015-09-28 03:48:34.835128"], ["updated_at", "2015-09-28 03:48:34.836861"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2415]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2014]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2014 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2014 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2014 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'CMXgwo5kicvJr8Gsj_C65ACM2adfG2KTAOUAzpAl_nSw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.845649"], ["target_id", 2014], ["target_type", "User"], ["token", "CMXgwo5kicvJr8Gsj_C65ACM2adfG2KTAOUAzpAl_nSw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.845649"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.1ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 13:48:34 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b892cf6ca_11a343fd84906020066761@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:34.853617"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:34.853617"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2015 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.856881"], ["state", "pending"], ["target_id", 2015], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.856881"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2416]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2015]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2015 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2015 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:34.865053"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:34.865053"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2016 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.868289"], ["state", "pending"], ["target_id", 2016], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.868289"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2417]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2016]] NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2016 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2016]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2016 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2417 [["sent_time", "2015-09-28 03:48:34.874356"], ["state", "sent"], ["updated_at", "2015-09-28 03:48:34.877111"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2016 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:34.883518"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:34.883518"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2017 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.887073"], ["state", "pending"], ["target_id", 2017], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.887073"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2017 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.890719"], ["state", "pending"], ["target_id", 2017], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.890719"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2419]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2017]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2017 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2017]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2017 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2419 [["sent_time", "2015-09-28 03:48:34.895487"], ["state", "sent"], ["updated_at", "2015-09-28 03:48:34.898107"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2017]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2017 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2418 [["sent_time", "2015-09-28 03:48:34.899951"], ["state", "sent"], ["updated_at", "2015-09-28 03:48:34.902467"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2017 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2017 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:34.910430"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:34.910430"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2018 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.913749"], ["state", "read"], ["target_id", 2018], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.913749"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2420]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2018]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2018 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.8ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:34.921901"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:34.921901"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2019 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2019 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:34.928320"], ["group_id", 2], ["state", "pending"], ["target_id", 2019], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.928320"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2421]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2019]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2019 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2019]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2019 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2019 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2421 [["sent_time", "2015-09-28 03:48:34.934003"], ["state", "sent"], ["updated_at", "2015-09-28 03:48:34.937903"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2019 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2019 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2421]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2019]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2019 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2019 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2019 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2019 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '2xwyp305sAaKvr-gDeES9AiZZtbwfGaPT9GNlRWdXBpg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:34.950261"], ["target_id", 2019], ["target_type", "User"], ["token", "2xwyp305sAaKvr-gDeES9AiZZtbwfGaPT9GNlRWdXBpg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.950261"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.6ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 13:48:34 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b892e8dbc_11a343fd8490602006686a@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:34.957968"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:34.957968"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2020 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2020 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:34.962756"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2020], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.962756"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2020 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2020 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2422 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:34.967904"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2020 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2020 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2422 [["sent_time", "2015-09-28 03:48:34.969303"], ["updated_at", "2015-09-28 03:48:34.971958"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2422]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:34.979042"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:34.979042"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2021 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2021 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:34.983067"], ["group_id", 1], ["state", "pending"], ["target_id", 2021], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.983067"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2021 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2423) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:34.988868"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:34.988868"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2022 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2022 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:34.993219"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2022], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.993219"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2022 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2022 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:34.997523"], ["group_id", 1], ["state", "pending"], ["target_id", 2022], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:34.997523"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2022 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2425) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.003347"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.003347"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2023 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2023 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.007834"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2023], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.007834"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2023 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2023 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.012523"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2023], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.012523"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2023 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2023 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.016734"], ["group_id", 1], ["state", "pending"], ["target_id", 2023], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.016734"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2023 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2428) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.023142"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.023142"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2024 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2024 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.027709"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 2024], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.027709"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2024 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2024 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.032050"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 2024], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.032050"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2024 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2024 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.036912"], ["group_id", 1], ["state", "pending"], ["target_id", 2024], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.036912"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2024 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2431) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.043178"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.043178"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2025 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2025 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.047259"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2025], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.047259"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2025 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2025 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.051465"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2025], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.051465"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2025 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2025 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.055983"], ["group_id", 1], ["state", "pending"], ["target_id", 2025], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.055983"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2025 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2434) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.061640"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.061640"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2026 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2026 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 17:48:35.062650"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2026], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.065861"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2026 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:48:35.068072') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2026 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:48:35.068072') ORDER BY created_at DESC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2026 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2026 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:48:35.073955"], ["group_id", 1], ["parent_id", 2435], ["state", "pending"], ["target_id", 2026], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.073955"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.077923"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.077923"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2027 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2027 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:48:35.079071"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2027], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.082254"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2027 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:48:35.084252')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2027 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2027 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.088263"], ["group_id", 1], ["state", "pending"], ["target_id", 2027], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.088263"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.092048"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.092048"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2028 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2028 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:48:35.093170"], ["group_id", 1], ["state", "pending"], ["target_id", 2028], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.096390"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2028 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:48:35.098455')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2028 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2028 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.102082"], ["group_id", 1], ["state", "pending"], ["target_id", 2028], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.102082"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.106410"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.106410"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2029 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2029 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.111376"], ["group_id", 1], ["state", "pending"], ["target_id", 2029], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.111376"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2029 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2441) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2029 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2441) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.117934"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.117934"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2030 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2030 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.122080"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2030], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.122080"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2030 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2030 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2442 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.125951"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2030 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2030 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2442 [["sent_time", "2015-09-28 03:48:35.127087"], ["updated_at", "2015-09-28 03:48:35.129531"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2030 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2030 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.133547"], ["group_id", 1], ["state", "pending"], ["target_id", 2030], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.133547"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2030 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2443) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2030 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2443) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.140555"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.140555"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2031 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2031 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.144885"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2031], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.144885"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2031 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2031 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2444 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.148661"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2031 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2031 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2444 [["sent_time", "2015-09-28 03:48:35.150120"], ["updated_at", "2015-09-28 03:48:35.153388"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2031 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2031 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.157592"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2031], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.157592"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2031 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2031 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2445 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.161762"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2031 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2031 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2445 [["sent_time", "2015-09-28 03:48:35.162892"], ["updated_at", "2015-09-28 03:48:35.170911"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2031 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2031 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.175651"], ["group_id", 1], ["state", "pending"], ["target_id", 2031], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.175651"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2031 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2446) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2031 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2446) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.184408"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.184408"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.189312"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2032], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.189312"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2447 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.193849"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2447 [["sent_time", "2015-09-28 03:48:35.195238"], ["updated_at", "2015-09-28 03:48:35.197997"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.203201"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2032], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.203201"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2448 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.207859"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2448 [["sent_time", "2015-09-28 03:48:35.209502"], ["updated_at", "2015-09-28 03:48:35.212476"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.217985"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2032], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.217985"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2449 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.221957"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2449 [["sent_time", "2015-09-28 03:48:35.223775"], ["updated_at", "2015-09-28 03:48:35.226463"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.231114"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2032], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.231114"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2450 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.235685"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2450 [["sent_time", "2015-09-28 03:48:35.236976"], ["updated_at", "2015-09-28 03:48:35.239677"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.244130"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2032], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.244130"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2451 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.248660"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2451 [["sent_time", "2015-09-28 03:48:35.250020"], ["updated_at", "2015-09-28 03:48:35.252563"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.256798"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2032], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.256798"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2452 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.260634"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2452 [["sent_time", "2015-09-28 03:48:35.261712"], ["updated_at", "2015-09-28 03:48:35.264044"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.268392"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2032], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.268392"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2453 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.272552"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2453 [["sent_time", "2015-09-28 03:48:35.273775"], ["updated_at", "2015-09-28 03:48:35.276543"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.280848"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2032], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.280848"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2454 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.285097"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2454 [["sent_time", "2015-09-28 03:48:35.286195"], ["updated_at", "2015-09-28 03:48:35.288753"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.292977"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2032], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.292977"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2455 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.296999"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2455 [["sent_time", "2015-09-28 03:48:35.298146"], ["updated_at", "2015-09-28 03:48:35.300585"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.305242"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2032], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.305242"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2456 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.309344"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2456 [["sent_time", "2015-09-28 03:48:35.310462"], ["updated_at", "2015-09-28 03:48:35.313194"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.317723"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2032], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.317723"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2457 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.322151"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2457 [["sent_time", "2015-09-28 03:48:35.323369"], ["updated_at", "2015-09-28 03:48:35.326070"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2032 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.330741"], ["group_id", 1], ["state", "pending"], ["target_id", 2032], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.330741"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2032 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2458) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2032 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2458) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.339195"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.339195"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2033 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2033 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.343953"], ["group_id", 1], ["state", "pending"], ["target_id", 2033], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.343953"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2033 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2033 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2033 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2459)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2033 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2033 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2459 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.355185"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.360596"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.360596"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2034 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2034 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.365265"], ["group_id", 1], ["state", "pending"], ["target_id", 2034], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.365265"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2034 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2034 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2034 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2460)  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2034 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2034 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2460 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.375059"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.380038"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.380038"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2035 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2035 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.385257"], ["group_id", 1], ["state", "pending"], ["target_id", 2035], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.385257"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2035 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2035 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2035 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2461)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2035 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2035 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2461 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.394005"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2461]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.400325"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.400325"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2036 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2036 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.404934"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2036], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.404934"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2036 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2036 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:50:35.404934"], ["group_id", 1], ["state", "pending"], ["target_id", 2036], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.409323"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2036 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2036 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2036 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2463)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2036 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2036 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2463 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:48:35.417839"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.423052"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.423052"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2037 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2037 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.428018"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2037], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.428018"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2037 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:48:35.429913') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2037 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:48:35.429913') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2037 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2037 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:50:35.428018"], ["group_id", 1], ["parent_id", 2464], ["state", "pending"], ["target_id", 2037], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.435282"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2465]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.440318"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.440318"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2038 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2038 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.444656"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2038], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.444656"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2038 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2038 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.449385"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2038], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.449385"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2038 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2038 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.453739"], ["group_id", 1], ["state", "pending"], ["target_id", 2038], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.453739"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2038 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2038 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2038 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2468)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.462360"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.462360"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2039 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2039 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.467069"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2039], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.467069"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2039 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2039 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.472259"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2039], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.472259"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2039 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2039 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:48:35.476822"], ["group_id", 1], ["state", "pending"], ["target_id", 2039], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.476822"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2039 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2039 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2039 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2471) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2471]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.487625"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.487625"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2040 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.494994"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.494994"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2041 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2041 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.503359"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.503359"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2042 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.511380"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.511380"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2043 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.514961"], ["state", "pending"], ["target_id", 2043], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.514961"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2043) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:48:35.518195"], ["target_id", 2043], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.518195"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2043 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.524207"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.524207"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2044 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.528451"], ["state", "pending"], ["target_id", 2044], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.528451"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2044 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.534808"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.534808"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2045 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.538408"], ["state", "pending"], ["target_id", 2045], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.538408"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2045) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:48:35.541660"], ["target_id", 2045], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:48:35.541660"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2045 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2045 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.549014"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.549014"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2046 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.554087"], ["state", "pending"], ["target_id", 2046], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.554087"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2046 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2046 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.560891"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.560891"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2047 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.564348"], ["state", "pending"], ["target_id", 2047], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.564348"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2047) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.567822"], ["group_id", 1], ["target_id", 2047], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.567822"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2047 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2047 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.576615"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.576615"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2048 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.580144"], ["state", "pending"], ["target_id", 2048], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.580144"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2048) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:48:35.583204"], ["target_id", 2048], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.583204"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2048 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2048 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.592408"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.592408"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2049 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.596111"], ["state", "pending"], ["target_id", 2049], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.596111"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2049 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2049 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2478 [["group_id", 1], ["updated_at", "2015-09-28 03:48:35.600724"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2049 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2049 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.609591"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.609591"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2050 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.613030"], ["state", "pending"], ["target_id", 2050], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.613030"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2479]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2050]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2050 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2050 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.621850"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.621850"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2051 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.625242"], ["state", "pending"], ["target_id", 2051], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.625242"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2051) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:48:35.628645"], ["target_id", 2051], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:48:35.628645"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2480]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2051]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2051 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2051 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.637413"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.637413"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2052 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.640739"], ["state", "pending"], ["target_id", 2052], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.640739"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2052) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.644025"], ["group_id", 1], ["target_id", 2052], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.644025"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2052 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2481]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2052]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2052 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.653808"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.653808"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2053 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.657086"], ["state", "pending"], ["target_id", 2053], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.657086"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2053 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2053 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.663743"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.663743"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2054 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.667410"], ["state", "pending"], ["target_id", 2054], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.667410"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2054) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:48:35.670746"], ["target_id", 2054], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:48:35.670746"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2054 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2054 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.678928"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.678928"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2055 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.682844"], ["state", "pending"], ["target_id", 2055], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.682844"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2055) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.686237"], ["group_id", 1], ["target_id", 2055], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.686237"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2055 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2055 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.694554"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.694554"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2056 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.698198"], ["state", "pending"], ["target_id", 2056], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.698198"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2056 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'evIhkmIuNGttZsWyjadFGw2EiVwSDSCEix-lpVHmxJrg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.701901"], ["target_id", 2056], ["target_type", "User"], ["token", "evIhkmIuNGttZsWyjadFGw2EiVwSDSCEix-lpVHmxJrg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.701901"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.707046"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.707046"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2057 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.710967"], ["state", "pending"], ["target_id", 2057], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.710967"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2057 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.4ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ICJHvV9aTk_JVAkZKUY-tQdTanX4fGSptDY2jHXcLrjw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.714788"], ["target_id", 2057], ["target_type", "User"], ["token", "ICJHvV9aTk_JVAkZKUY-tQdTanX4fGSptDY2jHXcLrjw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.714788"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2057 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:48:35.722213"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:48:35.722213"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2058 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.725805"], ["state", "pending"], ["target_id", 2058], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.725805"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2058 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '5XZFkeEPYQ7kmvown3Ok0QzRDjeQdvj0Fs641j7v00AQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.729337"], ["target_id", 2058], ["target_type", "User"], ["token", "5XZFkeEPYQ7kmvown3Ok0QzRDjeQdvj0Fs641j7v00AQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.729337"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 255 [["active", "f"], ["updated_at", "2015-09-28 03:48:35.732026"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2058 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'kwFEkBf1cbo030VWdRyE6wynGDoIlx9UKs3NAWnK8lfA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:48:35.735501"], ["target_id", 2058], ["target_type", "User"], ["token", "kwFEkBf1cbo030VWdRyE6wynGDoIlx9UKs3NAWnK8lfA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:48:35.735501"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.435579"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.435579"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2059 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.465449"], ["state", "pending"], ["target_id", 2059], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.465449"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 2059 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.472936"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.472936"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2060 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.476308"], ["state", "pending"], ["target_id", 2060], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.476308"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.480371"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.480371"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2061 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.483559"], ["state", "pending"], ["target_id", 2061], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.483559"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.487710"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.487710"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2062 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.491262"], ["state", "pending"], ["target_id", 2062], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.491262"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2062 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2491 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:49:12.494225"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.502878"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.502878"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.506521"], ["state", "pending"], ["target_id", 2063], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.506521"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2063 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2492 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:49:12.511312"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.516703"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.516703"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.519973"], ["state", "pending"], ["target_id", 2064], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.519973"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2064 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2493 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:49:12.523154"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.528674"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.528674"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2065 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.531989"], ["state", "pending"], ["target_id", 2065], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.531989"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2065 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2494 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:49:12.534799"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.540004"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.540004"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2066 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.543419"], ["state", "pending"], ["target_id", 2066], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.543419"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2066 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2495]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.550498"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.550498"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2067 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.554227"], ["state", "pending"], ["target_id", 2067], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.554227"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2067 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2067 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2496 [["state", "sent"], ["updated_at", "2015-09-28 03:49:12.560531"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2067 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2496 [["sent_time", "2015-09-28 03:49:12.561918"], ["updated_at", "2015-09-28 03:49:12.563824"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2496]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.569268"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.569268"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2068 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.572563"], ["state", "pending"], ["target_id", 2068], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.572563"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2068 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2497]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.579315"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.579315"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2069 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.582399"], ["state", "pending"], ["target_id", 2069], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.582399"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2069 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-27 02:49:12.583707"], ["state", "pending"], ["target_id", 2069], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.585776"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2069 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2498]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.593253"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.593253"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2070 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.596895"], ["state", "pending"], ["target_id", 2070], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.596895"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2070 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-27 04:49:12.598306"], ["state", "pending"], ["target_id", 2070], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.600439"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2070 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2500]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.623896"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.623896"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2071 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.627426"], ["state", "pending"], ["target_id", 2071], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.627426"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2071 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2071 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2502)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2071 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2502 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:12.633426"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2502]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2071]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2071 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2071]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2071 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2502 [["sent_time", "2015-09-28 03:49:12.642420"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:12.645226"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2071 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2502]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2071]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2071 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2071 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.3ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (2.7ms) NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2071 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '_uRXbawN_6BxItpa28CcBg4hca1KDAmAWuOUh1pNWj2g' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.690263"], ["target_id", 2071], ["target_type", "User"], ["token", "_uRXbawN_6BxItpa28CcBg4hca1KDAmAWuOUh1pNWj2g"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.690263"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 171.2ms Sent mail to user@example.com (5.8ms) Date: Mon, 28 Sep 2015 13:49:12 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b8b8cac61_11c583fd338c60200959ae@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.835688"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.835688"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2072 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.839510"], ["state", "pending_as_aggregation_parent"], ["target_id", 2072], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.839510"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2072 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.843017"], ["state", "pending"], ["target_id", 2072], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.843017"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2072 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2072 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2504)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.850201"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.850201"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2073 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.853464"], ["state", "pending"], ["target_id", 2073], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.853464"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2073 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2073 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2505 [["state", "sent"], ["updated_at", "2015-09-28 03:49:12.857604"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2073 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2505 [["sent_time", "2015-09-28 03:49:12.858803"], ["updated_at", "2015-09-28 03:49:12.860163"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2505]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2073]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2073 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2073 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2073 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '4RM0bPY2BRuNYfXf3te1bwMXufMhgEfKiF7S4uf0aIBQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.869096"], ["target_id", 2073], ["target_type", "User"], ["token", "4RM0bPY2BRuNYfXf3te1bwMXufMhgEfKiF7S4uf0aIBQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.869096"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.7ms Sent mail to user@example.com (1.6ms) Date: Mon, 28 Sep 2015 13:49:12 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b8b8d50b3_11c583fd338c6020096036@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.877307"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.877307"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2074 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.880537"], ["state", "pending"], ["target_id", 2074], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.880537"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2074 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2506 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 03:49:12.883623"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.887721"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.887721"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2075 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.891338"], ["state", "pending"], ["target_id", 2075], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.891338"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2075) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:49:12.896533"], ["target_id", 2075], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:49:12.896533"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2507]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2075]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2075 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2075 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.905403"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.905403"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2076 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.908709"], ["state", "pending"], ["target_id", 2076], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.908709"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2508]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2076]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2076 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2076 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.917971"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.917971"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2077 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.921314"], ["state", "pending"], ["target_id", 2077], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.921314"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2077 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2077 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2509 [["state", "sent"], ["updated_at", "2015-09-28 03:49:12.926040"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2077 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2509 [["sent_time", "2015-09-28 03:49:12.927268"], ["updated_at", "2015-09-28 03:49:12.928624"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2509]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2077]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2077 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2077 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2077 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'OVGpI-aJZ96jc3ezzCfmlQdhh3-oZ58VhIsJU4zykReA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.936878"], ["target_id", 2077], ["target_type", "User"], ["token", "OVGpI-aJZ96jc3ezzCfmlQdhh3-oZ58VhIsJU4zykReA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.936878"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.5ms Sent mail to user@example.com (1.6ms) Date: Mon, 28 Sep 2015 13:49:12 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b8b8e5912_11c583fd338c6020096129@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.944412"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.944412"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2078 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.947448"], ["state", "pending"], ["target_id", 2078], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.947448"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2510]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2078]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2078 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2078 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.956421"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.956421"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2079 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.960519"], ["state", "pending"], ["target_id", 2079], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.960519"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2511]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2079]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2079 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2079]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2079 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2511 [["sent_time", "2015-09-28 03:49:12.965045"], ["state", "sent"], ["updated_at", "2015-09-28 03:49:12.967870"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2079 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:12.974163"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:12.974163"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2080 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.977511"], ["state", "pending"], ["target_id", 2080], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.977511"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2080 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:12.980807"], ["state", "pending"], ["target_id", 2080], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:12.980807"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2513]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2080]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2080 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2080]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2080 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2513 [["sent_time", "2015-09-28 03:49:12.985048"], ["state", "sent"], ["updated_at", "2015-09-28 03:49:12.987374"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2080]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2080 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2512 [["sent_time", "2015-09-28 03:49:12.989250"], ["state", "sent"], ["updated_at", "2015-09-28 03:49:12.991575"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2080 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2080 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.000034"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.000034"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2081 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.004082"], ["state", "read"], ["target_id", 2081], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.004082"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2514]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2081]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2081 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.011482"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.011482"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2082 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2082 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.015782"], ["group_id", 2], ["state", "pending"], ["target_id", 2082], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.015782"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2515]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2082]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2082 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2082]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2082 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2082 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2515 [["sent_time", "2015-09-28 03:49:13.020919"], ["state", "sent"], ["updated_at", "2015-09-28 03:49:13.024542"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2082 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2082 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2515]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2082]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2082 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2082 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2082 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2082 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'xItYs1QSkNi-uYwTUOnBKwxe-26pl7duEZm655w1iEkg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.036966"], ["target_id", 2082], ["target_type", "User"], ["token", "xItYs1QSkNi-uYwTUOnBKwxe-26pl7duEZm655w1iEkg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.036966"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.1ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 13:49:13 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b8b99e00_11c583fd338c602009623c@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.4ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.045423"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.045423"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2083 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2083 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.049869"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2083], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.049869"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2083 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2083 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2516 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.053979"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2083 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2083 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2516 [["sent_time", "2015-09-28 03:49:13.055266"], ["updated_at", "2015-09-28 03:49:13.058086"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2516]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.065076"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.065076"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2084 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2084 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.069528"], ["group_id", 1], ["state", "pending"], ["target_id", 2084], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.069528"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2084 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2517) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.075222"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.075222"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2085 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2085 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.080595"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2085], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.080595"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2085 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2085 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.086136"], ["group_id", 1], ["state", "pending"], ["target_id", 2085], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.086136"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2085 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2519) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.091898"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.091898"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2086 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2086 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.096107"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2086], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.096107"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2086 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2086 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.100700"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2086], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.100700"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2086 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2086 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.104963"], ["group_id", 1], ["state", "pending"], ["target_id", 2086], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.104963"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2086 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2522) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.110323"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.110323"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2087 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2087 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.114706"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 2087], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.114706"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2087 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2087 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.118983"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 2087], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.118983"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2087 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2087 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.122952"], ["group_id", 1], ["state", "pending"], ["target_id", 2087], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.122952"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2087 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2525) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.128806"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.128806"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2088 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2088 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.133260"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2088], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.133260"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2088 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2088 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.138485"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2088], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.138485"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2088 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2088 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.142855"], ["group_id", 1], ["state", "pending"], ["target_id", 2088], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.142855"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2088 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2528) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.149002"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.149002"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2089 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2089 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 17:49:13.150183"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2089], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.153594"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2089 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:49:13.155546') NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2089 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:49:13.155546') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2089 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2089 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:49:13.161060"], ["group_id", 1], ["parent_id", 2529], ["state", "pending"], ["target_id", 2089], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.161060"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.165388"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.165388"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2090 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2090 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:49:13.166513"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2090], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.171089"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2090 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:49:13.173186')  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2090 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2090 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.180044"], ["group_id", 1], ["state", "pending"], ["target_id", 2090], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.180044"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.184355"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.184355"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2091 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2091 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:49:13.185394"], ["group_id", 1], ["state", "pending"], ["target_id", 2091], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.188413"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2091 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:49:13.190433')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2091 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2091 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.194909"], ["group_id", 1], ["state", "pending"], ["target_id", 2091], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.194909"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.198813"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.198813"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2092 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2092 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.203482"], ["group_id", 1], ["state", "pending"], ["target_id", 2092], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.203482"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2092 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2535) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2092 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2535) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.210707"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.210707"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2093 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2093 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.215069"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2093], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.215069"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2093 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2093 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2536 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.219443"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2093 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2093 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2536 [["sent_time", "2015-09-28 03:49:13.220774"], ["updated_at", "2015-09-28 03:49:13.223077"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2093 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2093 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.228248"], ["group_id", 1], ["state", "pending"], ["target_id", 2093], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.228248"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2093 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2537) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2093 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2537) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.235237"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.235237"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2094 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2094 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.239626"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2094], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.239626"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2094 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2094 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2538 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.243743"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2094 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2094 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2538 [["sent_time", "2015-09-28 03:49:13.244899"], ["updated_at", "2015-09-28 03:49:13.247135"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2094 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2094 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.251630"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2094], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.251630"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2094 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2094 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2539 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.255428"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2094 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2094 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2539 [["sent_time", "2015-09-28 03:49:13.256601"], ["updated_at", "2015-09-28 03:49:13.259066"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2094 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2094 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.263514"], ["group_id", 1], ["state", "pending"], ["target_id", 2094], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.263514"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2094 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2540) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2094 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2540) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.270800"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.270800"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.275398"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2095], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.275398"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2541 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.281115"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2541 [["sent_time", "2015-09-28 03:49:13.282381"], ["updated_at", "2015-09-28 03:49:13.284926"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.289299"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2095], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.289299"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2542 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.293184"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2542 [["sent_time", "2015-09-28 03:49:13.294325"], ["updated_at", "2015-09-28 03:49:13.296858"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.301102"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2095], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.301102"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2543 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.305361"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2543 [["sent_time", "2015-09-28 03:49:13.306460"], ["updated_at", "2015-09-28 03:49:13.308732"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.313304"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2095], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.313304"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2544 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.318376"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2544 [["sent_time", "2015-09-28 03:49:13.319656"], ["updated_at", "2015-09-28 03:49:13.322399"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.326812"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2095], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.326812"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2545 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.330910"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2545 [["sent_time", "2015-09-28 03:49:13.332026"], ["updated_at", "2015-09-28 03:49:13.334414"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.338579"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2095], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.338579"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2546 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.342415"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2546 [["sent_time", "2015-09-28 03:49:13.343738"], ["updated_at", "2015-09-28 03:49:13.346202"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.350486"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2095], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.350486"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2547 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.354310"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2547 [["sent_time", "2015-09-28 03:49:13.355416"], ["updated_at", "2015-09-28 03:49:13.357772"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.361965"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2095], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.361965"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2548 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.365973"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2548 [["sent_time", "2015-09-28 03:49:13.367198"], ["updated_at", "2015-09-28 03:49:13.369617"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.373836"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2095], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.373836"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2549 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.378054"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2549 [["sent_time", "2015-09-28 03:49:13.379219"], ["updated_at", "2015-09-28 03:49:13.381739"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.385972"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2095], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.385972"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2550 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.390013"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2550 [["sent_time", "2015-09-28 03:49:13.391122"], ["updated_at", "2015-09-28 03:49:13.393701"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.397882"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2095], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.397882"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2551 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.401832"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2551 [["sent_time", "2015-09-28 03:49:13.402976"], ["updated_at", "2015-09-28 03:49:13.405278"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2095 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.409449"], ["group_id", 1], ["state", "pending"], ["target_id", 2095], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.409449"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2095 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2552) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2095 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2552) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.417201"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.417201"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2096 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2096 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.421812"], ["group_id", 1], ["state", "pending"], ["target_id", 2096], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.421812"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2096 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2096 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2096 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2553)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2096 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2096 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2553 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.431169"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.436008"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.436008"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2097 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2097 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.440101"], ["group_id", 1], ["state", "pending"], ["target_id", 2097], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.440101"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2097 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2097 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2097 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2554)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2097 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2097 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2554 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.453782"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.459055"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.459055"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2098 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2098 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.464637"], ["group_id", 1], ["state", "pending"], ["target_id", 2098], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.464637"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2098 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2098 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2098 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2555)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2098 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2098 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2555 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.473258"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2555]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.479647"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.479647"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2099 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2099 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.484596"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2099], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.484596"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2099 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2099 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:13.484596"], ["group_id", 1], ["state", "pending"], ["target_id", 2099], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.489430"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2099 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2099 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2099 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2557)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2099 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2099 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2557 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:49:13.498752"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.504823"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.504823"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2100 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2100 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.509796"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2100], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.509796"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2100 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:49:13.512260') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2100 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:49:13.512260') ORDER BY created_at DESC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2100 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2100 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:51:13.509796"], ["group_id", 1], ["parent_id", 2558], ["state", "pending"], ["target_id", 2100], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.518171"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2559]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.523609"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.523609"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2101 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2101 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.527971"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2101], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.527971"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2101 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2101 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.532585"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2101], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.532585"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2101 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2101 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.536836"], ["group_id", 1], ["state", "pending"], ["target_id", 2101], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.536836"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2101 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2101 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2101 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2562)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.546244"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.546244"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2102 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2102 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.550943"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2102], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.550943"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2102 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2102 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.555192"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2102], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.555192"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2102 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2102 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:49:13.559423"], ["group_id", 1], ["state", "pending"], ["target_id", 2102], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.559423"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2102 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2102 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2102 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2565) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2565]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.568660"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.568660"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2103 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.574308"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.574308"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2104 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2104 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.582234"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.582234"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2105 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.589415"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.589415"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2106 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.592735"], ["state", "pending"], ["target_id", 2106], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.592735"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2106) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:49:13.595642"], ["target_id", 2106], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.595642"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2106 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.601175"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.601175"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2107 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.604556"], ["state", "pending"], ["target_id", 2107], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.604556"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2107 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.610103"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.610103"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2108 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.613312"], ["state", "pending"], ["target_id", 2108], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.613312"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2108) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:49:13.616345"], ["target_id", 2108], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:49:13.616345"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2108 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2108 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.623949"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.623949"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2109 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.629060"], ["state", "pending"], ["target_id", 2109], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.629060"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2109 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2109 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.635871"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.635871"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2110 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.639198"], ["state", "pending"], ["target_id", 2110], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.639198"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2110) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.642127"], ["group_id", 1], ["target_id", 2110], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.642127"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2110 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2110 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.649443"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.649443"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2111 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.653157"], ["state", "pending"], ["target_id", 2111], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.653157"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2111) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:49:13.656340"], ["target_id", 2111], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.656340"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2111 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2111 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.664086"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.664086"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2112 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.668538"], ["state", "pending"], ["target_id", 2112], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.668538"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2112 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2112 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2572 [["group_id", 1], ["updated_at", "2015-09-28 03:49:13.673251"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2112 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2112 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.682165"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.682165"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2113 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.685442"], ["state", "pending"], ["target_id", 2113], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.685442"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2573]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2113]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2113 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2113 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.693895"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.693895"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2114 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.697414"], ["state", "pending"], ["target_id", 2114], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.697414"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2114) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:49:13.700339"], ["target_id", 2114], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:49:13.700339"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2574]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2114]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2114 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2114 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.710001"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.710001"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2115 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.713672"], ["state", "pending"], ["target_id", 2115], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.713672"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2115) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.716820"], ["group_id", 1], ["target_id", 2115], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.716820"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2115 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2575]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2115]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2115 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.726713"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.726713"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2116 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.730236"], ["state", "pending"], ["target_id", 2116], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.730236"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2116 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2116 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.737415"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.737415"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2117 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.741105"], ["state", "pending"], ["target_id", 2117], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.741105"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2117) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:49:13.744287"], ["target_id", 2117], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:49:13.744287"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2117 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2117 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.752128"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.752128"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2118 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.755850"], ["state", "pending"], ["target_id", 2118], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.755850"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2118) LIMIT 1 SQL (0.5ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.760467"], ["group_id", 1], ["target_id", 2118], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.760467"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2118 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2118 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.769271"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.769271"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2119 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.773400"], ["state", "pending"], ["target_id", 2119], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.773400"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2119 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'CEQX7g6Qcj-CDu296XnCZAK0bnoEMZwseue-AbmpOaRQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.777364"], ["target_id", 2119], ["target_type", "User"], ["token", "CEQX7g6Qcj-CDu296XnCZAK0bnoEMZwseue-AbmpOaRQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.777364"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.782886"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.782886"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2120 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.787137"], ["state", "pending"], ["target_id", 2120], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.787137"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2120 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'hLY973yRmrDaTLs6SstJOQ1kgFcd_cFOjGMAaQ8purCw' LIMIT 1 SQL (0.5ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.791099"], ["target_id", 2120], ["target_type", "User"], ["token", "hLY973yRmrDaTLs6SstJOQ1kgFcd_cFOjGMAaQ8purCw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.791099"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2120 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:13.799238"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:13.799238"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2121 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.803173"], ["state", "pending"], ["target_id", 2121], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.803173"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2121 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'TbKmY0Vbyl0XtW-mXVPs8QAEsYrLDOfbcU3H3H1wR_KQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.806985"], ["target_id", 2121], ["target_type", "User"], ["token", "TbKmY0Vbyl0XtW-mXVPs8QAEsYrLDOfbcU3H3H1wR_KQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.806985"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 263 [["active", "f"], ["updated_at", "2015-09-28 03:49:13.809775"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2121 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '3kAPSc3DRarSpeo2SrOp8Qz5S-QzpwAuxiadkN03Ul7w' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:13.813045"], ["target_id", 2121], ["target_type", "User"], ["token", "3kAPSc3DRarSpeo2SrOp8Qz5S-QzpwAuxiadkN03Ul7w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:13.813045"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:49:48.803189"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:49:48.803189"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2122 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:49:48.834262"], ["state", "pending"], ["target_id", 2122], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:48.834262"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2122 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-27 04:49:48.836430"], ["state", "pending"], ["target_id", 2122], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:49:48.838678"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2122 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2582]]  (0.3ms) ROLLBACK  (0.3ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:50:44.497558"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:50:44.497558"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2123 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:50:44.532932"], ["state", "pending"], ["target_id", 2123], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:50:44.532932"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2123 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2123 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:50:44.539566') NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2123 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:50:44.539566') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2123 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2584]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:02.446868"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:02.446868"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2124 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:02.475247"], ["state", "pending"], ["target_id", 2124], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:02.475247"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 2124 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:02.482879"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:02.482879"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2125 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:02.486211"], ["state", "pending"], ["target_id", 2125], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:02.486211"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:02.490490"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:02.490490"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2126 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:02.494006"], ["state", "pending"], ["target_id", 2126], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:02.494006"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:02.498016"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:02.498016"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2127 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:02.501419"], ["state", "pending"], ["target_id", 2127], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:02.501419"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2127 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2588 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:51:02.504646"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:02.513290"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:02.513290"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2128 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:02.516789"], ["state", "pending"], ["target_id", 2128], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:02.516789"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2128 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2589 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:51:02.519944"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:02.524889"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:02.524889"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2129 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:02.529522"], ["state", "pending"], ["target_id", 2129], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:02.529522"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2129 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2590 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:51:02.533051"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:02.539012"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:02.539012"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2130 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:02.542712"], ["state", "pending"], ["target_id", 2130], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:02.542712"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2130 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2591 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:51:02.545712"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:02.551149"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:02.551149"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2131 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:02.554557"], ["state", "pending"], ["target_id", 2131], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:02.554557"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2131 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2592]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:02.562046"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:02.562046"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2132 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:02.565559"], ["state", "pending"], ["target_id", 2132], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:02.565559"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2132 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2132 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2593 [["state", "sent"], ["updated_at", "2015-09-28 03:51:02.570410"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2132 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2593 [["sent_time", "2015-09-28 03:51:02.571614"], ["updated_at", "2015-09-28 03:51:02.573218"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2593]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:02.579719"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:02.579719"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2133 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:02.583632"], ["state", "pending"], ["target_id", 2133], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:02.583632"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2133 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:51:02.587157') NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2133 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:51:02.587157') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2133 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2594]]  (0.8ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:02.599337"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:02.599337"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2134 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:02.608058"], ["state", "pending"], ["target_id", 2134], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:02.608058"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2134 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) ROLLBACK TO SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2134 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:51:02.619152') NewPostNotification Load (1.0ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2134 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:51:02.619152') ORDER BY created_at DESC LIMIT 1  (0.7ms) SAVEPOINT active_record_1  (2.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2134 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (1.0ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2595]]  (0.5ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:02.645336"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:02.645336"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2135 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:02.650734"], ["state", "pending"], ["target_id", 2135], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:02.650734"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2135 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2135 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:51:02.656060') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2135 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:51:02.656060') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2135 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2596]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.9ms) SAVEPOINT active_record_1 SQL (1.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:02.671090"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:02.671090"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (2.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2136 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (4.7ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:02.696515"], ["state", "pending"], ["target_id", 2136], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:02.696515"]]  (1.6ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2136 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2136 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2597)  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2136 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2597 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:02.722655"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2597]] User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2136]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2136 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2136]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2136 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2597 [["sent_time", "2015-09-28 03:51:02.741032"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:02.744943"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2136 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2597]] User Load (0.5ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2136]]  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2136 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (2.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2136 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.3ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (3.4ms) NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2136 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (1.0ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '4z913JpAFdnlTucfOTexBgoB7SVR8d5iGVu3KjoXh2aA' LIMIT 1 SQL (0.6ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:02.822933"], ["target_id", 2136], ["target_type", "User"], ["token", "4z913JpAFdnlTucfOTexBgoB7SVR8d5iGVu3KjoXh2aA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:02.822933"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 249.4ms Sent mail to user@example.com (8.0ms) Date: Mon, 28 Sep 2015 13:51:03 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b9277772_122563fe70946020063614@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.036813"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.036813"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2137 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.040561"], ["state", "pending_as_aggregation_parent"], ["target_id", 2137], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.040561"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2137 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.044090"], ["state", "pending"], ["target_id", 2137], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.044090"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2137 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2137 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2599)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.051332"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.051332"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2138 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.054970"], ["state", "pending"], ["target_id", 2138], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.054970"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2138 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2138 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2600 [["state", "sent"], ["updated_at", "2015-09-28 03:51:03.059689"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2138 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2600 [["sent_time", "2015-09-28 03:51:03.060851"], ["updated_at", "2015-09-28 03:51:03.062324"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2600]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2138]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2138 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2138 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2138 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '7vHBhoVJO-5jGIQ6FFTXGgg2KYi8ouF7gS6waPjKcd_Q' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.072618"], ["target_id", 2138], ["target_type", "User"], ["token", "7vHBhoVJO-5jGIQ6FFTXGgg2KYi8ouF7gS6waPjKcd_Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.072618"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.8ms Sent mail to user@example.com (1.7ms) Date: Mon, 28 Sep 2015 13:51:03 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b9271289f_122563fe7094602006376a@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.080878"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.080878"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2139 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.084321"], ["state", "pending"], ["target_id", 2139], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.084321"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2139 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2601 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 03:51:03.087329"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.091689"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.091689"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2140 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.095012"], ["state", "pending"], ["target_id", 2140], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.095012"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2140) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:51:03.100338"], ["target_id", 2140], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:51:03.100338"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2602]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2140]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2140 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2140 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.108998"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.108998"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2141 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.112089"], ["state", "pending"], ["target_id", 2141], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.112089"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2603]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2141]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2141 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2141 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.120382"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.120382"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2142 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.123584"], ["state", "pending"], ["target_id", 2142], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.123584"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2142 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2142 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2604 [["state", "sent"], ["updated_at", "2015-09-28 03:51:03.128847"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2142 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2604 [["sent_time", "2015-09-28 03:51:03.130223"], ["updated_at", "2015-09-28 03:51:03.131708"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2604]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2142]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2142 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2142 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2142 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'e6CrqTR6x8BdoEsFdc2bAw1-Pg76GZxcV9Mp1t1aHxFg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.140010"], ["target_id", 2142], ["target_type", "User"], ["token", "e6CrqTR6x8BdoEsFdc2bAw1-Pg76GZxcV9Mp1t1aHxFg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.140010"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.5ms Sent mail to user@example.com (2.0ms) Date: Mon, 28 Sep 2015 13:51:03 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b927230f4_122563fe70946020063825@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.148180"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.148180"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2143 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.151564"], ["state", "pending"], ["target_id", 2143], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.151564"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2605]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2143]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2143 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2143 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.159506"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.159506"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2144 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.162803"], ["state", "pending"], ["target_id", 2144], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.162803"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2606]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2144]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2144 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2144]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2144 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2606 [["sent_time", "2015-09-28 03:51:03.168434"], ["state", "sent"], ["updated_at", "2015-09-28 03:51:03.171146"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2144 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.177497"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.177497"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2145 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.183151"], ["state", "pending"], ["target_id", 2145], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.183151"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2145 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.186732"], ["state", "pending"], ["target_id", 2145], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.186732"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2608]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2145]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2145 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2145]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2145 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2608 [["sent_time", "2015-09-28 03:51:03.191281"], ["state", "sent"], ["updated_at", "2015-09-28 03:51:03.193776"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2145]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2145 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2607 [["sent_time", "2015-09-28 03:51:03.195621"], ["state", "sent"], ["updated_at", "2015-09-28 03:51:03.198357"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2145 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2145 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.206500"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.206500"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2146 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.209751"], ["state", "read"], ["target_id", 2146], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.209751"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2609]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2146]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2146 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.217289"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.217289"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2147 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2147 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.222060"], ["group_id", 2], ["state", "pending"], ["target_id", 2147], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.222060"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2610]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2147]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2147 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.1ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2147]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2147 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2147 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2610 [["sent_time", "2015-09-28 03:51:03.227217"], ["state", "sent"], ["updated_at", "2015-09-28 03:51:03.232275"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2147 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2147 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2610]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2147]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2147 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2147 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2147 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.3ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2147 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '4tpkOk2QXWu6fzwC4r1VnwQiu9wbVbKlbQ9-Z2L4pqoA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.244813"], ["target_id", 2147], ["target_type", "User"], ["token", "4tpkOk2QXWu6fzwC4r1VnwQiu9wbVbKlbQ9-Z2L4pqoA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.244813"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.8ms Sent mail to user@example.com (2.1ms) Date: Mon, 28 Sep 2015 13:51:03 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b9273cb81_122563fe70946020063987@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.252823"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.252823"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2148 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2148 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.257254"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2148], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.257254"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2148 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2148 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2611 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.261341"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2148 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2148 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2611 [["sent_time", "2015-09-28 03:51:03.262524"], ["updated_at", "2015-09-28 03:51:03.265300"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2611]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.272479"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.272479"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2149 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.277372"], ["group_id", 1], ["state", "pending"], ["target_id", 2149], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.277372"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2149 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2612) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.8ms) ROLLBACK  (0.3ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.295487"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.295487"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.302575"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.302575"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2150 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.306871"], ["group_id", 1], ["state", "pending"], ["target_id", 2150], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.306871"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2150 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2614) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.312473"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.312473"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2151 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2151 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.317186"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2151], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.317186"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2151 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2151 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.321515"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2151], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.321515"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2151 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2151 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.326463"], ["group_id", 1], ["state", "pending"], ["target_id", 2151], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.326463"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2151 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2617) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.332923"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.332923"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.337363"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 2152], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.337363"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.341650"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 2152], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.341650"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2152 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.345929"], ["group_id", 1], ["state", "pending"], ["target_id", 2152], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.345929"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2152 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2620) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.351681"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.351681"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.355999"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2153], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.355999"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.360091"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2153], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.360091"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2153 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.364296"], ["group_id", 1], ["state", "pending"], ["target_id", 2153], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.364296"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2153 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2623) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.370714"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.370714"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2154 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2154 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 17:51:03.371994"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2154], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.375353"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2154 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:51:03.377148') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2154 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:51:03.377148') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2154 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2154 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:51:03.384640"], ["group_id", 1], ["parent_id", 2624], ["state", "pending"], ["target_id", 2154], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.384640"]]  (0.9ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.396843"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.396843"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2155 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2155 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:51:03.398192"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2155], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.401663"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2155 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:51:03.403733')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2155 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2155 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.407797"], ["group_id", 1], ["state", "pending"], ["target_id", 2155], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.407797"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.411949"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.411949"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2156 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2156 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:51:03.412968"], ["group_id", 1], ["state", "pending"], ["target_id", 2156], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.416902"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2156 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:51:03.419250')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2156 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2156 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.423172"], ["group_id", 1], ["state", "pending"], ["target_id", 2156], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.423172"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.427194"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.427194"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2157 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2157 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.432569"], ["group_id", 1], ["state", "pending"], ["target_id", 2157], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.432569"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2157 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2630) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2157 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2630) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.439710"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.439710"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2158 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2158 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.444171"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2158], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.444171"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2158 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2158 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2631 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.448490"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2158 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2158 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2631 [["sent_time", "2015-09-28 03:51:03.450121"], ["updated_at", "2015-09-28 03:51:03.452760"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2158 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2158 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.457146"], ["group_id", 1], ["state", "pending"], ["target_id", 2158], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.457146"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2158 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2632) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2158 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2632) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.464114"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.464114"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.468691"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2159], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.468691"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2633 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.472723"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2633 [["sent_time", "2015-09-28 03:51:03.473948"], ["updated_at", "2015-09-28 03:51:03.476386"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.481962"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2159], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.481962"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2634 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.485982"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2634 [["sent_time", "2015-09-28 03:51:03.487108"], ["updated_at", "2015-09-28 03:51:03.489497"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2159 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.494067"], ["group_id", 1], ["state", "pending"], ["target_id", 2159], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.494067"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2159 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2635) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2159 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2635) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.501631"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.501631"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.506089"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2160], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.506089"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2636 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.510182"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2636 [["sent_time", "2015-09-28 03:51:03.511274"], ["updated_at", "2015-09-28 03:51:03.513574"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.517986"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2160], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.517986"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2637 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.521952"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2637 [["sent_time", "2015-09-28 03:51:03.523075"], ["updated_at", "2015-09-28 03:51:03.525410"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.529651"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2160], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.529651"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2638 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.533879"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2638 [["sent_time", "2015-09-28 03:51:03.535170"], ["updated_at", "2015-09-28 03:51:03.537771"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.542411"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2160], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.542411"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2639 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.547199"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2639 [["sent_time", "2015-09-28 03:51:03.548614"], ["updated_at", "2015-09-28 03:51:03.551398"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.555744"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2160], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.555744"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2640 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.559629"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2640 [["sent_time", "2015-09-28 03:51:03.560772"], ["updated_at", "2015-09-28 03:51:03.563219"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.567926"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2160], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.567926"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2641 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.572203"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2641 [["sent_time", "2015-09-28 03:51:03.573369"], ["updated_at", "2015-09-28 03:51:03.575811"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.580368"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2160], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.580368"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2642 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.584710"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2642 [["sent_time", "2015-09-28 03:51:03.586039"], ["updated_at", "2015-09-28 03:51:03.588693"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.594413"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2160], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.594413"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2643 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.599541"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2643 [["sent_time", "2015-09-28 03:51:03.600871"], ["updated_at", "2015-09-28 03:51:03.603643"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.608172"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2160], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.608172"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2644 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.612052"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2644 [["sent_time", "2015-09-28 03:51:03.613380"], ["updated_at", "2015-09-28 03:51:03.616048"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.620443"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2160], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.620443"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2645 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.625090"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2645 [["sent_time", "2015-09-28 03:51:03.626175"], ["updated_at", "2015-09-28 03:51:03.628745"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.633706"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2160], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.633706"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2646 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.637829"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2646 [["sent_time", "2015-09-28 03:51:03.638955"], ["updated_at", "2015-09-28 03:51:03.641251"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2160 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.645784"], ["group_id", 1], ["state", "pending"], ["target_id", 2160], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.645784"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2160 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2647) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2160 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2647) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.653870"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.653870"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2161 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2161 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.658288"], ["group_id", 1], ["state", "pending"], ["target_id", 2161], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.658288"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2161 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2161 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2161 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2648)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2161 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2161 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2648 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.669237"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.674270"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.674270"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2162 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2162 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.678801"], ["group_id", 1], ["state", "pending"], ["target_id", 2162], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.678801"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2162 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2162 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2162 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2649)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2162 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2162 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2649 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.692553"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.698818"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.698818"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2163 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2163 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.704142"], ["group_id", 1], ["state", "pending"], ["target_id", 2163], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.704142"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2163 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2163 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2163 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2650)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2163 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2163 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2650 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.713195"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2650]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.719858"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.719858"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2164 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2164 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.724875"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2164], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.724875"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2164 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2164 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:03.724875"], ["group_id", 1], ["state", "pending"], ["target_id", 2164], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.730386"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2164 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2164 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2164 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2652)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2164 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2164 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2652 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:51:03.742646"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.749194"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.749194"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2165 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2165 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.754311"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2165], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.754311"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2165 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:51:03.756688') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2165 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:51:03.756688') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2165 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2165 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:53:03.754311"], ["group_id", 1], ["parent_id", 2653], ["state", "pending"], ["target_id", 2165], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.763439"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2654]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.769640"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.769640"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2166 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2166 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.774753"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2166], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.774753"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2166 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2166 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.1ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.779854"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2166], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.779854"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2166 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2166 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.795710"], ["group_id", 1], ["state", "pending"], ["target_id", 2166], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.795710"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2166 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2166 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2166 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2657)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.807526"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.807526"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2167 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2167 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.812136"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2167], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.812136"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2167 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2167 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.816665"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2167], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.816665"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2167 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2167 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:51:03.821004"], ["group_id", 1], ["state", "pending"], ["target_id", 2167], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.821004"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2167 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2167 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2167 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2660) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2660]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.829958"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.829958"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2168 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.835613"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.835613"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2169 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2169 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.842720"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.842720"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2170 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.850364"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.850364"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2171 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.853750"], ["state", "pending"], ["target_id", 2171], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.853750"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2171) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:51:03.856770"], ["target_id", 2171], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.856770"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2171 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.862560"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.862560"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2172 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.866413"], ["state", "pending"], ["target_id", 2172], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.866413"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2172 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.872027"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.872027"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2173 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.875737"], ["state", "pending"], ["target_id", 2173], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.875737"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2173) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:51:03.879182"], ["target_id", 2173], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:51:03.879182"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2173 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2173 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.886053"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.886053"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2174 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.889565"], ["state", "pending"], ["target_id", 2174], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.889565"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2174 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2174 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.896742"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.896742"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2175 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.900728"], ["state", "pending"], ["target_id", 2175], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.900728"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2175) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.903751"], ["group_id", 1], ["target_id", 2175], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.903751"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2175 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2175 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.911456"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.911456"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2176 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.915001"], ["state", "pending"], ["target_id", 2176], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.915001"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2176) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:51:03.918056"], ["target_id", 2176], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.918056"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2176 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2176 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.926026"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.926026"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2177 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.929441"], ["state", "pending"], ["target_id", 2177], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.929441"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2177 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2177 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2667 [["group_id", 1], ["updated_at", "2015-09-28 03:51:03.934177"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2177 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2177 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.941481"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.941481"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2178 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.945275"], ["state", "pending"], ["target_id", 2178], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.945275"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2668]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2178]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2178 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2178 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.955002"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.955002"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2179 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.958526"], ["state", "pending"], ["target_id", 2179], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.958526"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2179) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:51:03.961589"], ["target_id", 2179], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:51:03.961589"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2669]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2179]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2179 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2179 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.969769"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.969769"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2180 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.973287"], ["state", "pending"], ["target_id", 2180], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.973287"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2180) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.976460"], ["group_id", 1], ["target_id", 2180], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.976460"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2180 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2670]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2180]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2180 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.986776"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.986776"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2181 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:03.990378"], ["state", "pending"], ["target_id", 2181], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:03.990378"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2181 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2181 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:03.998120"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:03.998120"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2182 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:04.001637"], ["state", "pending"], ["target_id", 2182], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:04.001637"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2182) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:51:04.004724"], ["target_id", 2182], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:51:04.004724"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2182 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2182 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:04.011630"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:04.011630"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2183 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:04.015009"], ["state", "pending"], ["target_id", 2183], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:04.015009"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2183) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:04.017930"], ["group_id", 1], ["target_id", 2183], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:04.017930"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2183 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2183 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:04.025553"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:04.025553"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2184 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:04.029380"], ["state", "pending"], ["target_id", 2184], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:04.029380"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2184 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'zW_RerqvAqMRfXDTCEaFXgoP7jP6wr-cKqWPaxKTLtdw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:04.033971"], ["target_id", 2184], ["target_type", "User"], ["token", "zW_RerqvAqMRfXDTCEaFXgoP7jP6wr-cKqWPaxKTLtdw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:04.033971"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:04.041565"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:04.041565"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2185 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:04.045876"], ["state", "pending"], ["target_id", 2185], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:04.045876"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2185 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'mLz7Cqw9OqyxM6b45V0ljw25N6crOzEaM8EPDmDuNmdg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:04.050528"], ["target_id", 2185], ["target_type", "User"], ["token", "mLz7Cqw9OqyxM6b45V0ljw25N6crOzEaM8EPDmDuNmdg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:04.050528"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2185 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:51:04.057400"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:51:04.057400"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2186 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:04.061056"], ["state", "pending"], ["target_id", 2186], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:04.061056"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2186 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '3fNfdH1YWEf-HIbnBYt1yQakoU2VQGuqO_cZeBrv-WGA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:04.064760"], ["target_id", 2186], ["target_type", "User"], ["token", "3fNfdH1YWEf-HIbnBYt1yQakoU2VQGuqO_cZeBrv-WGA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:04.064760"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 271 [["active", "f"], ["updated_at", "2015-09-28 03:51:04.067707"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2186 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '2B8GcFguTZI1XerHe6_7qg62ra5r5lSyxqX7BboLyTHA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:51:04.071599"], ["target_id", 2186], ["target_type", "User"], ["token", "2B8GcFguTZI1XerHe6_7qg62ra5r5lSyxqX7BboLyTHA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:51:04.071599"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.245858"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.245858"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2187 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.276702"], ["state", "pending"], ["target_id", 2187], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.276702"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 2187 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.284237"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.284237"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2188 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.287737"], ["state", "pending"], ["target_id", 2188], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.287737"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.292282"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.292282"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2189 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.295761"], ["state", "pending"], ["target_id", 2189], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.295761"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.300604"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.300604"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2190 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.304161"], ["state", "pending"], ["target_id", 2190], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.304161"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2190 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2680 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:52:00.307280"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.315817"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.315817"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2191 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.319500"], ["state", "pending"], ["target_id", 2191], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.319500"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2191 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2681 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:52:00.322497"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.328046"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.328046"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2192 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.332178"], ["state", "pending"], ["target_id", 2192], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.332178"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2192 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2682 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:52:00.335331"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.340404"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.340404"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2193 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.343637"], ["state", "pending"], ["target_id", 2193], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.343637"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2193 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2683 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:52:00.346671"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.352172"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.352172"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2194 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.355444"], ["state", "pending"], ["target_id", 2194], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.355444"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2194 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2684]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.362968"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.362968"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2195 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.366440"], ["state", "pending"], ["target_id", 2195], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.366440"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2195 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2195 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2685 [["state", "sent"], ["updated_at", "2015-09-28 03:52:00.371709"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2195 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2685 [["sent_time", "2015-09-28 03:52:00.372873"], ["updated_at", "2015-09-28 03:52:00.374496"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2685]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.381061"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.381061"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2196 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.384444"], ["state", "pending"], ["target_id", 2196], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.384444"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2196 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:00.387794') NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2196 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:00.387794') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2196 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2686]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.397123"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.397123"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2197 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.400543"], ["state", "pending"], ["target_id", 2197], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.400543"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2197 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2197 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:00.405172') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2197 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:00.405172') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2197 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2687]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.413645"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.413645"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2198 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.417258"], ["state", "pending"], ["target_id", 2198], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.417258"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2198 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2198 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:00.421550') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2198 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:00.421550') ORDER BY created_at DESC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2198 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2688]]  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.431182"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.431182"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2199 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.434738"], ["state", "pending"], ["target_id", 2199], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.434738"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2199 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2199 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2689)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2199 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2689 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:00.441725"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2689]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2199]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2199 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2199]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2199 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2689 [["sent_time", "2015-09-28 03:52:00.450899"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:00.453887"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2199 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2689]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2199]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2199 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2199 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.3ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (2.6ms) NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2199 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '_kwN1MYoGHwB9DloMsvOlggmXQyfCgWV-ye_RAC8v7kQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.497824"], ["target_id", 2199], ["target_type", "User"], ["token", "_kwN1MYoGHwB9DloMsvOlggmXQyfCgWV-ye_RAC8v7kQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.497824"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 178.3ms Sent mail to user@example.com (5.8ms) Date: Mon, 28 Sep 2015 13:52:00 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b9609dec4_1247a3fc97c46020019399@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.652237"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.652237"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2200 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.655520"], ["state", "pending_as_aggregation_parent"], ["target_id", 2200], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.655520"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2200 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.659265"], ["state", "pending"], ["target_id", 2200], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.659265"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2200 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2200 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2691)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.666297"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.666297"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2201 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.669399"], ["state", "pending"], ["target_id", 2201], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.669399"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2201 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2201 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2692 [["state", "sent"], ["updated_at", "2015-09-28 03:52:00.673432"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2201 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2692 [["sent_time", "2015-09-28 03:52:00.674652"], ["updated_at", "2015-09-28 03:52:00.676023"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2692]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2201]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2201 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2201 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2201 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'NCEyAPfkgvTHf6eOBewc5AUCfvBRYn96IoZn2HjISFEg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.685154"], ["target_id", 2201], ["target_type", "User"], ["token", "NCEyAPfkgvTHf6eOBewc5AUCfvBRYn96IoZn2HjISFEg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.685154"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.4ms Sent mail to user@example.com (1.9ms) Date: Mon, 28 Sep 2015 13:52:00 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b960a84b6_1247a3fc97c460200194d6@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.693277"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.693277"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.697927"], ["state", "pending"], ["target_id", 2202], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.697927"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2202 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2693 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 03:52:00.701002"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.705533"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.705533"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.708784"], ["state", "pending"], ["target_id", 2203], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.708784"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2203) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:00.714206"], ["target_id", 2203], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:52:00.714206"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2694]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2203]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2203 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.722660"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.722660"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2204 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.726091"], ["state", "pending"], ["target_id", 2204], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.726091"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2695]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2204]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2204 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2204 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.734973"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.734973"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2205 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.738314"], ["state", "pending"], ["target_id", 2205], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.738314"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2205 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2205 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2696 [["state", "sent"], ["updated_at", "2015-09-28 03:52:00.742888"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2205 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2696 [["sent_time", "2015-09-28 03:52:00.744497"], ["updated_at", "2015-09-28 03:52:00.747033"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2696]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2205]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2205 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2205 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2205 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'tc9Dp8QRNouvxG1DlayH1Q5GkRxmxMt9Uj21P_qhy6UA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.755922"], ["target_id", 2205], ["target_type", "User"], ["token", "tc9Dp8QRNouvxG1DlayH1Q5GkRxmxMt9Uj21P_qhy6UA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.755922"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.8ms Sent mail to user@example.com (1.7ms) Date: Mon, 28 Sep 2015 13:52:00 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b960b9737_1247a3fc97c46020019526@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.763868"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.763868"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2206 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.767627"], ["state", "pending"], ["target_id", 2206], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.767627"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2697]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2206]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2206 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2206 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.775974"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.775974"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2207 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.779387"], ["state", "pending"], ["target_id", 2207], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.779387"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2698]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2207]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2207 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2207]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2207 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2698 [["sent_time", "2015-09-28 03:52:00.784488"], ["state", "sent"], ["updated_at", "2015-09-28 03:52:00.786915"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2207 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.792788"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.792788"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2208 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.796832"], ["state", "pending"], ["target_id", 2208], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.796832"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2208 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.800788"], ["state", "pending"], ["target_id", 2208], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.800788"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2700]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2208]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2208 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2208]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2208 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2700 [["sent_time", "2015-09-28 03:52:00.805163"], ["state", "sent"], ["updated_at", "2015-09-28 03:52:00.807525"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2208]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2208 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2699 [["sent_time", "2015-09-28 03:52:00.809185"], ["state", "sent"], ["updated_at", "2015-09-28 03:52:00.811742"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2208 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2208 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.820371"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.820371"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2209 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.823762"], ["state", "read"], ["target_id", 2209], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.823762"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2701]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2209]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2209 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.831269"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.831269"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:00.835868"], ["group_id", 2], ["state", "pending"], ["target_id", 2210], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.835868"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2702]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2210]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2210 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2210]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2702 [["sent_time", "2015-09-28 03:52:00.840730"], ["state", "sent"], ["updated_at", "2015-09-28 03:52:00.845008"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2702]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2210]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2210 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2210 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'dEznOhGe8ZhATwBi6gr8MQVPAlswTmuZGhmHl-9WLeUw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:00.857526"], ["target_id", 2210], ["target_type", "User"], ["token", "dEznOhGe8ZhATwBi6gr8MQVPAlswTmuZGhmHl-9WLeUw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.857526"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.6ms Sent mail to user@example.com (2.2ms) Date: Mon, 28 Sep 2015 13:52:00 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b960d240d_1247a3fc97c460200196db@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.865736"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.865736"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2211 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2211 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:00.870263"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2211], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.870263"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2211 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2211 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2703 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:00.874372"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2211 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2211 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2703 [["sent_time", "2015-09-28 03:52:00.875494"], ["updated_at", "2015-09-28 03:52:00.877805"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2703]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.885072"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.885072"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2212 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2212 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:00.889639"], ["group_id", 1], ["state", "pending"], ["target_id", 2212], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.889639"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2212 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2704) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.895672"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.895672"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2213 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2213 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:00.900837"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2213], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.900837"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2213 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2213 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:00.905056"], ["group_id", 1], ["state", "pending"], ["target_id", 2213], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.905056"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2213 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2706) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.911299"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.911299"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2214 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2214 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:00.915891"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2214], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.915891"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2214 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2214 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:00.920143"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2214], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.920143"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2214 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2214 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:00.924438"], ["group_id", 1], ["state", "pending"], ["target_id", 2214], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.924438"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2214 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2709) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.930453"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.930453"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2215 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2215 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:00.935286"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 2215], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.935286"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2215 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2215 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:00.939496"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 2215], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.939496"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2215 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2215 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:00.943691"], ["group_id", 1], ["state", "pending"], ["target_id", 2215], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.943691"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2215 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2712) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.950556"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.950556"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2216 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2216 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:00.954993"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2216], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.954993"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2216 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2216 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:00.959413"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2216], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.959413"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2216 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2216 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:00.963823"], ["group_id", 1], ["state", "pending"], ["target_id", 2216], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.963823"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2216 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2715) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.969289"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.969289"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2217 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2217 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 17:52:00.970738"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2217], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.974690"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2217 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:00.976743') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2217 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:00.976743') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2217 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2217 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:52:00.982084"], ["group_id", 1], ["parent_id", 2716], ["state", "pending"], ["target_id", 2217], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.982084"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:00.986291"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:00.986291"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2218 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2218 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:52:00.987607"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2218], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.990887"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2218 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:00.992925')  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2218 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2218 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:00.998069"], ["group_id", 1], ["state", "pending"], ["target_id", 2218], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:00.998069"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.002272"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.002272"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2219 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2219 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:52:01.003328"], ["group_id", 1], ["state", "pending"], ["target_id", 2219], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.006644"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2219 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:01.008775')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2219 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2219 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.012572"], ["group_id", 1], ["state", "pending"], ["target_id", 2219], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.012572"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.016458"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.016458"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2220 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2220 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.021211"], ["group_id", 1], ["state", "pending"], ["target_id", 2220], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.021211"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2220 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2722) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2220 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2722) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.028405"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.028405"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.033137"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2221], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.033137"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2723 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.037139"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2723 [["sent_time", "2015-09-28 03:52:01.038294"], ["updated_at", "2015-09-28 03:52:01.040581"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2221 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.045851"], ["group_id", 1], ["state", "pending"], ["target_id", 2221], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.045851"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2221 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2724) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2221 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2724) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.053422"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.053422"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.057752"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2222], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.057752"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2725 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.061728"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2725 [["sent_time", "2015-09-28 03:52:01.062894"], ["updated_at", "2015-09-28 03:52:01.065171"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.069468"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2222], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.069468"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2726 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.073765"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2726 [["sent_time", "2015-09-28 03:52:01.074941"], ["updated_at", "2015-09-28 03:52:01.077822"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2222 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.082644"], ["group_id", 1], ["state", "pending"], ["target_id", 2222], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.082644"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2222 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2727) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2222 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2727) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.090121"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.090121"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.094437"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2223], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.094437"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2728 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.099541"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2728 [["sent_time", "2015-09-28 03:52:01.100775"], ["updated_at", "2015-09-28 03:52:01.103489"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.108146"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2223], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.108146"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2729 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.112194"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2729 [["sent_time", "2015-09-28 03:52:01.113436"], ["updated_at", "2015-09-28 03:52:01.115826"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.120527"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2223], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.120527"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2730 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.124885"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2730 [["sent_time", "2015-09-28 03:52:01.126066"], ["updated_at", "2015-09-28 03:52:01.128614"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.133405"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2223], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.133405"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2731 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.137365"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2731 [["sent_time", "2015-09-28 03:52:01.138529"], ["updated_at", "2015-09-28 03:52:01.140951"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.146347"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2223], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.146347"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2732 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.150776"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2732 [["sent_time", "2015-09-28 03:52:01.151965"], ["updated_at", "2015-09-28 03:52:01.154350"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.158734"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2223], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.158734"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2733 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.162847"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2733 [["sent_time", "2015-09-28 03:52:01.164014"], ["updated_at", "2015-09-28 03:52:01.166299"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.170757"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2223], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.170757"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2734 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.174805"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2734 [["sent_time", "2015-09-28 03:52:01.175953"], ["updated_at", "2015-09-28 03:52:01.178441"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.182918"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2223], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.182918"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2735 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.186828"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2735 [["sent_time", "2015-09-28 03:52:01.187891"], ["updated_at", "2015-09-28 03:52:01.190399"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.194970"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2223], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.194970"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2736 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.198834"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2736 [["sent_time", "2015-09-28 03:52:01.199988"], ["updated_at", "2015-09-28 03:52:01.202415"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.206769"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2223], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.206769"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2737 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.210583"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2737 [["sent_time", "2015-09-28 03:52:01.211692"], ["updated_at", "2015-09-28 03:52:01.214091"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.218446"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2223], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.218446"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2738 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.222464"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2738 [["sent_time", "2015-09-28 03:52:01.223554"], ["updated_at", "2015-09-28 03:52:01.226092"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2223 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.230707"], ["group_id", 1], ["state", "pending"], ["target_id", 2223], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.230707"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2223 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2739) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2223 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2739) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.238355"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.238355"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2224 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2224 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.242731"], ["group_id", 1], ["state", "pending"], ["target_id", 2224], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.242731"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2224 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2224 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2224 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2740)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2224 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2224 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2740 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.252541"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.257286"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.257286"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2225 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2225 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.262087"], ["group_id", 1], ["state", "pending"], ["target_id", 2225], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.262087"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2225 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2225 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2225 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2741)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2225 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2225 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2741 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.275945"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.282264"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.282264"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2226 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2226 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.287377"], ["group_id", 1], ["state", "pending"], ["target_id", 2226], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.287377"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2226 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2226 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2226 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2742)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2226 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2226 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2742 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.296343"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2742]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.302785"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.302785"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2227 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2227 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.307985"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2227], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.307985"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2227 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2227 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:54:01.307985"], ["group_id", 1], ["state", "pending"], ["target_id", 2227], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.312846"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2227 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2227 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2227 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2744)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2227 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2227 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2744 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:01.323409"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.329681"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.329681"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2228 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2228 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.335011"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2228], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.335011"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2228 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:01.337301') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2228 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:01.337301') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2228 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2228 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:54:01.335011"], ["group_id", 1], ["parent_id", 2745], ["state", "pending"], ["target_id", 2228], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.343230"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2746]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.349488"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.349488"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2229 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2229 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.353759"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2229], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.353759"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2229 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2229 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.357965"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2229], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.357965"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2229 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2229 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.361986"], ["group_id", 1], ["state", "pending"], ["target_id", 2229], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.361986"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2229 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2229 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2229 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2749)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.370879"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.370879"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2230 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2230 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.375346"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2230], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.375346"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2230 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2230 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.381459"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2230], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.381459"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2230 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2230 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:01.386335"], ["group_id", 1], ["state", "pending"], ["target_id", 2230], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.386335"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2230 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2230 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2230 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2752) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2752]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.396034"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.396034"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2231 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.401869"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.401869"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2232 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2232 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.409140"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.409140"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2233 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.415905"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.415905"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2234 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.419896"], ["state", "pending"], ["target_id", 2234], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.419896"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2234) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:01.423607"], ["target_id", 2234], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.423607"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2234 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.429629"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.429629"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2235 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.433544"], ["state", "pending"], ["target_id", 2235], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.433544"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2235 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.439207"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.439207"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2236 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.442608"], ["state", "pending"], ["target_id", 2236], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.442608"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2236) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:01.445833"], ["target_id", 2236], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:52:01.445833"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2236 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2236 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.452910"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.452910"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2237 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.456778"], ["state", "pending"], ["target_id", 2237], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.456778"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2237 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2237 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.464078"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.464078"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2238 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.468001"], ["state", "pending"], ["target_id", 2238], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.468001"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2238) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.471003"], ["group_id", 1], ["target_id", 2238], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.471003"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2238 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2238 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.480049"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.480049"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2239 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.484099"], ["state", "pending"], ["target_id", 2239], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.484099"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2239) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:01.487169"], ["target_id", 2239], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.487169"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2239 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2239 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.494947"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.494947"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2240 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.498481"], ["state", "pending"], ["target_id", 2240], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.498481"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2240 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2240 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2759 [["group_id", 1], ["updated_at", "2015-09-28 03:52:01.502770"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2240 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2240 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.510036"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.510036"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2241 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.514706"], ["state", "pending"], ["target_id", 2241], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.514706"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2760]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2241]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2241 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2241 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.523636"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.523636"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2242 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.527139"], ["state", "pending"], ["target_id", 2242], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.527139"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2242) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:01.531238"], ["target_id", 2242], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:52:01.531238"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2761]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2242]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2242 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2242 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.540190"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.540190"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2243 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.544146"], ["state", "pending"], ["target_id", 2243], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.544146"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2243) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.547611"], ["group_id", 1], ["target_id", 2243], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.547611"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2243 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2762]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2243]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2243 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.558456"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.558456"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.561833"], ["state", "pending"], ["target_id", 2244], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.561833"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2244 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.569633"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.569633"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.573007"], ["state", "pending"], ["target_id", 2245], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.573007"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2245) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:01.575969"], ["target_id", 2245], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:52:01.575969"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2245 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.584420"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.584420"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2246 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.587854"], ["state", "pending"], ["target_id", 2246], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.587854"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2246) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.590960"], ["group_id", 1], ["target_id", 2246], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.590960"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2246 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2246 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.599395"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.599395"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2247 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.603368"], ["state", "pending"], ["target_id", 2247], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.603368"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2247 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'KihhFeWN06OQ5VCU6oTmRQ7DI1ig-4e1RaCNPOcdjepQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.607587"], ["target_id", 2247], ["target_type", "User"], ["token", "KihhFeWN06OQ5VCU6oTmRQ7DI1ig-4e1RaCNPOcdjepQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.607587"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.614039"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.614039"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2248 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.617969"], ["state", "pending"], ["target_id", 2248], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.617969"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2248 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '_7Qlq2jhH6s93jyGBnkCJQBO325leZx47qMawF_12XNQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.622166"], ["target_id", 2248], ["target_type", "User"], ["token", "_7Qlq2jhH6s93jyGBnkCJQBO325leZx47qMawF_12XNQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.622166"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2248 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:01.630157"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:01.630157"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2249 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.633788"], ["state", "pending"], ["target_id", 2249], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.633788"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2249 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'zu_axYoOMRaIrSDn-ylVjADrLbj0V2Slf1J20ivvmuNQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.637549"], ["target_id", 2249], ["target_type", "User"], ["token", "zu_axYoOMRaIrSDn-ylVjADrLbj0V2Slf1J20ivvmuNQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.637549"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 279 [["active", "f"], ["updated_at", "2015-09-28 03:52:01.640355"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2249 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'xx5Mw141_wzUsest3esAggR6FAMOWDm_jmsWbU0YTrJw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:01.644077"], ["target_id", 2249], ["target_type", "User"], ["token", "xx5Mw141_wzUsest3esAggR6FAMOWDm_jmsWbU0YTrJw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:01.644077"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.414828"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.414828"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2250 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.444260"], ["state", "pending"], ["target_id", 2250], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.444260"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 2250 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.451843"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.451843"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2251 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.455340"], ["state", "pending"], ["target_id", 2251], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.455340"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.459509"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.459509"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2252 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.462854"], ["state", "pending"], ["target_id", 2252], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.462854"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.467071"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.467071"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2253 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.471430"], ["state", "pending"], ["target_id", 2253], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.471430"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2253 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2772 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:52:32.474664"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.483503"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.483503"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2254 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.487137"], ["state", "pending"], ["target_id", 2254], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.487137"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2254 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2773 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:52:32.491320"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.496808"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.496808"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2255 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.500367"], ["state", "pending"], ["target_id", 2255], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.500367"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2255 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2774 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:52:32.503322"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.508807"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.508807"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2256 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.511998"], ["state", "pending"], ["target_id", 2256], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.511998"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2256 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2775 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:52:32.515204"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.520437"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.520437"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2257 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.523710"], ["state", "pending"], ["target_id", 2257], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.523710"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2257 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2776]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.530876"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.530876"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2258 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.534171"], ["state", "pending"], ["target_id", 2258], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.534171"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2258 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2258 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2777 [["state", "sent"], ["updated_at", "2015-09-28 03:52:32.540162"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2258 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2777 [["sent_time", "2015-09-28 03:52:32.541473"], ["updated_at", "2015-09-28 03:52:32.543077"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2777]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.548351"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.548351"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2259 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.551854"], ["state", "pending"], ["target_id", 2259], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.551854"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2259 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:32.555284') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2259 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:32.555284') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2259 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2778]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.564109"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.564109"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2260 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.567567"], ["state", "pending"], ["target_id", 2260], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.567567"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2260 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2260 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:32.572261') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2260 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:32.572261') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2260 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2779]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.582313"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.582313"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2261 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.585889"], ["state", "pending"], ["target_id", 2261], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.585889"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2261 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2261 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:32.590199') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2261 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:32.590199') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2261 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2780]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.598708"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.598708"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2262 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.602497"], ["state", "pending"], ["target_id", 2262], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.602497"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2262 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2262 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2781)  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2262 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2781 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:32.609743"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2781]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2262]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2262 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2262]]  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2262 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2781 [["sent_time", "2015-09-28 03:52:32.618926"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:32.622414"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2262 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2781]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2262]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2262 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2262 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.3ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (2.9ms) NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2262 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'LSz2t-07h-7xrP8Sphmphwtk6muc8tmkyAUNQpBBJ36w' LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.665536"], ["target_id", 2262], ["target_type", "User"], ["token", "LSz2t-07h-7xrP8Sphmphwtk6muc8tmkyAUNQpBBJ36w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.665536"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 170.0ms Sent mail to user@example.com (5.3ms) Date: Mon, 28 Sep 2015 13:52:32 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b980c4de1_1267d3fd1bc46020857921@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.811645"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.811645"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2263 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.815472"], ["state", "pending_as_aggregation_parent"], ["target_id", 2263], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.815472"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2263 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.818754"], ["state", "pending"], ["target_id", 2263], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.818754"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2263 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2263 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2783)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.832612"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.832612"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2264 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.835965"], ["state", "pending"], ["target_id", 2264], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.835965"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2264 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2264 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2784 [["state", "sent"], ["updated_at", "2015-09-28 03:52:32.840039"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2264 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2784 [["sent_time", "2015-09-28 03:52:32.841328"], ["updated_at", "2015-09-28 03:52:32.842656"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2784]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2264]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2264 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2264 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2264 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Hq1uNIgV29D1gB9Rp6H-KATk-e815RDSBctY_Dgfua7w' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.852252"], ["target_id", 2264], ["target_type", "User"], ["token", "Hq1uNIgV29D1gB9Rp6H-KATk-e815RDSBctY_Dgfua7w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.852252"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.9ms Sent mail to user@example.com (2.0ms) Date: Mon, 28 Sep 2015 13:52:32 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b980d113a_1267d3fd1bc46020858098@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.860242"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.860242"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2265 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.863636"], ["state", "pending"], ["target_id", 2265], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.863636"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2265 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2785 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 03:52:32.866555"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.870480"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.870480"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2266 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.873724"], ["state", "pending"], ["target_id", 2266], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.873724"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2266) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:32.879263"], ["target_id", 2266], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:52:32.879263"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2786]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2266]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2266 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2266 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.887985"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.887985"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2267 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.891111"], ["state", "pending"], ["target_id", 2267], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.891111"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2787]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2267]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2267 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2267 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.899588"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.899588"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2268 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.902605"], ["state", "pending"], ["target_id", 2268], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.902605"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2268 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2268 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2788 [["state", "sent"], ["updated_at", "2015-09-28 03:52:32.908065"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2268 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2788 [["sent_time", "2015-09-28 03:52:32.909333"], ["updated_at", "2015-09-28 03:52:32.910817"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2788]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2268]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2268 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2268 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2268 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'WNrmsfUU3lpPcHNmjrylpQ_UDiPTKcrWNYb47M7dDdrw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.918959"], ["target_id", 2268], ["target_type", "User"], ["token", "WNrmsfUU3lpPcHNmjrylpQ_UDiPTKcrWNYb47M7dDdrw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.918959"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.6ms Sent mail to user@example.com (1.6ms) Date: Mon, 28 Sep 2015 13:52:32 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b980e139e_1267d3fd1bc46020858143@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.926722"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.926722"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2269 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.930156"], ["state", "pending"], ["target_id", 2269], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.930156"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2789]] User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2269]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2269 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2269 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.938278"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.938278"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2270 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.942907"], ["state", "pending"], ["target_id", 2270], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.942907"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2790]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2270]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2270 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2270]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2270 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2790 [["sent_time", "2015-09-28 03:52:32.948477"], ["state", "sent"], ["updated_at", "2015-09-28 03:52:32.950870"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2270 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.956964"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.956964"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2271 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.960141"], ["state", "pending"], ["target_id", 2271], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.960141"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2271 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.963619"], ["state", "pending"], ["target_id", 2271], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.963619"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2792]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2271]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2271 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2271]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2271 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2792 [["sent_time", "2015-09-28 03:52:32.967963"], ["state", "sent"], ["updated_at", "2015-09-28 03:52:32.970360"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2271]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2271 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2791 [["sent_time", "2015-09-28 03:52:32.972178"], ["state", "sent"], ["updated_at", "2015-09-28 03:52:32.974678"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2271 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2271 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.983454"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.983454"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2272 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:32.986819"], ["state", "read"], ["target_id", 2272], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.986819"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2793]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2272]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2272 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:32.994957"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:32.994957"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2273 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2273 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:32.999574"], ["group_id", 2], ["state", "pending"], ["target_id", 2273], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:32.999574"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2794]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2273]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2273 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2273]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2273 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2273 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2794 [["sent_time", "2015-09-28 03:52:33.004431"], ["state", "sent"], ["updated_at", "2015-09-28 03:52:33.007778"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2273 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2273 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2794]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2273]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2273 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2273 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2273 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.3ms) NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2273 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '9SeLxLAaxEUQVI1SaTTS2wuMtNQM8zEtb3oPW4x0h9JA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.022582"], ["target_id", 2273], ["target_type", "User"], ["token", "9SeLxLAaxEUQVI1SaTTS2wuMtNQM8zEtb3oPW4x0h9JA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.022582"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.4ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 13:52:33 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b98166cc_1267d3fd1bc4602085824f@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.030271"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.030271"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2274 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2274 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.035011"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2274], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.035011"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2274 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2274 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.1ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2795 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.042732"]]  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2274 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2274 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2795 [["sent_time", "2015-09-28 03:52:33.047036"], ["updated_at", "2015-09-28 03:52:33.054077"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2795]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.061051"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.061051"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2275 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2275 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.065372"], ["group_id", 1], ["state", "pending"], ["target_id", 2275], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.065372"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2275 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2796) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.070889"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.070889"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2276 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2276 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.075138"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2276], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.075138"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2276 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2276 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.080188"], ["group_id", 1], ["state", "pending"], ["target_id", 2276], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.080188"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2276 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2798) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.086052"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.086052"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2277 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2277 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.091225"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2277], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.091225"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2277 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2277 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.095867"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2277], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.095867"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2277 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2277 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.100030"], ["group_id", 1], ["state", "pending"], ["target_id", 2277], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.100030"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2277 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2801) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.106246"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.106246"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2278 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2278 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.111368"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 2278], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.111368"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2278 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2278 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.115908"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 2278], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.115908"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2278 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2278 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.120388"], ["group_id", 1], ["state", "pending"], ["target_id", 2278], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.120388"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2278 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2804) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.126188"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.126188"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2279 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2279 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.131744"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2279], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.131744"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2279 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2279 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.135930"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2279], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.135930"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2279 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2279 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.140043"], ["group_id", 1], ["state", "pending"], ["target_id", 2279], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.140043"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2279 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2807) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.145846"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.145846"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2280 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2280 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 17:52:33.147016"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2280], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.150682"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2280 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:33.152655') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2280 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:33.152655') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2280 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2280 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:52:33.157642"], ["group_id", 1], ["parent_id", 2808], ["state", "pending"], ["target_id", 2280], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.157642"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.161646"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.161646"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2281 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2281 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:52:33.162741"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2281], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.166447"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2281 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:33.168285')  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2281 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2281 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.173287"], ["group_id", 1], ["state", "pending"], ["target_id", 2281], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.173287"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.177638"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.177638"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2282 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2282 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:52:33.178760"], ["group_id", 1], ["state", "pending"], ["target_id", 2282], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.182052"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2282 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:33.184462')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2282 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2282 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.188288"], ["group_id", 1], ["state", "pending"], ["target_id", 2282], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.188288"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.192505"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.192505"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2283 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2283 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.196819"], ["group_id", 1], ["state", "pending"], ["target_id", 2283], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.196819"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2283 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2814) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2283 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2814) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.203412"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.203412"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2284 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2284 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.207727"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2284], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.207727"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2284 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2284 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2815 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.212132"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2284 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2284 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2815 [["sent_time", "2015-09-28 03:52:33.213479"], ["updated_at", "2015-09-28 03:52:33.216023"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2284 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2284 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.220331"], ["group_id", 1], ["state", "pending"], ["target_id", 2284], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.220331"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2284 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2816) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2284 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2816) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.228366"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.228366"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.232738"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2285], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.232738"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2817 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.236784"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2817 [["sent_time", "2015-09-28 03:52:33.237989"], ["updated_at", "2015-09-28 03:52:33.240351"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.244761"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2285], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.244761"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2818 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.248600"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2818 [["sent_time", "2015-09-28 03:52:33.249742"], ["updated_at", "2015-09-28 03:52:33.252138"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2285 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.256343"], ["group_id", 1], ["state", "pending"], ["target_id", 2285], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.256343"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2285 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2819) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2285 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2819) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.264079"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.264079"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.268672"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2286], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.268672"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2820 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.274254"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2820 [["sent_time", "2015-09-28 03:52:33.275551"], ["updated_at", "2015-09-28 03:52:33.277997"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.282391"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2286], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.282391"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2821 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.286650"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2821 [["sent_time", "2015-09-28 03:52:33.287808"], ["updated_at", "2015-09-28 03:52:33.291050"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.295782"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2286], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.295782"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2822 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.299773"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2822 [["sent_time", "2015-09-28 03:52:33.300897"], ["updated_at", "2015-09-28 03:52:33.303424"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.307876"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2286], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.307876"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2823 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.313098"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2823 [["sent_time", "2015-09-28 03:52:33.314274"], ["updated_at", "2015-09-28 03:52:33.316781"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.321007"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2286], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.321007"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2824 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.325078"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2824 [["sent_time", "2015-09-28 03:52:33.326335"], ["updated_at", "2015-09-28 03:52:33.328835"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.332971"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2286], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.332971"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2825 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.336739"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2825 [["sent_time", "2015-09-28 03:52:33.337914"], ["updated_at", "2015-09-28 03:52:33.340289"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.344893"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2286], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.344893"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2826 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.349727"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2826 [["sent_time", "2015-09-28 03:52:33.351001"], ["updated_at", "2015-09-28 03:52:33.353695"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.357931"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2286], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.357931"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2827 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.362062"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2827 [["sent_time", "2015-09-28 03:52:33.363228"], ["updated_at", "2015-09-28 03:52:33.365790"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.369982"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2286], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.369982"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2828 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.373738"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2828 [["sent_time", "2015-09-28 03:52:33.374807"], ["updated_at", "2015-09-28 03:52:33.377603"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.382739"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2286], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.382739"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2829 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.386732"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2829 [["sent_time", "2015-09-28 03:52:33.387794"], ["updated_at", "2015-09-28 03:52:33.390350"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.394621"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2286], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.394621"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2830 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.398527"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2830 [["sent_time", "2015-09-28 03:52:33.399592"], ["updated_at", "2015-09-28 03:52:33.401899"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2286 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.406089"], ["group_id", 1], ["state", "pending"], ["target_id", 2286], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.406089"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2286 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2831) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2286 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2831) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.413972"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.413972"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2287 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2287 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.418556"], ["group_id", 1], ["state", "pending"], ["target_id", 2287], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.418556"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2287 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2287 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2287 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2832)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2287 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2287 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2832 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.428037"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.432643"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.432643"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2288 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2288 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.442471"], ["group_id", 1], ["state", "pending"], ["target_id", 2288], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.442471"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2288 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2288 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2288 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2833)  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2288 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2288 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2833 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.452075"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.458150"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.458150"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2289 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2289 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.463344"], ["group_id", 1], ["state", "pending"], ["target_id", 2289], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.463344"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2289 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2289 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2289 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2834)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2289 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2289 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2834 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.472213"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2834]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.478565"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.478565"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2290 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2290 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.484008"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2290], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.484008"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2290 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2290 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:54:33.484008"], ["group_id", 1], ["state", "pending"], ["target_id", 2290], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.488834"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2290 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2290 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2290 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2836)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2290 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2290 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2836 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:33.499409"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.505118"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.505118"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2291 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2291 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.510109"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2291], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.510109"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2291 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:33.512429') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2291 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:33.512429') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2291 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2291 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:54:33.510109"], ["group_id", 1], ["parent_id", 2837], ["state", "pending"], ["target_id", 2291], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.517672"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2838]]  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.522834"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.522834"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.527457"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2292], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.527457"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.532145"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2292], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.532145"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.536652"], ["group_id", 1], ["state", "pending"], ["target_id", 2292], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.536652"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2292 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2292 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2841)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.546537"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.546537"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2293 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2293 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.551345"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2293], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.551345"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2293 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2293 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.556197"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2293], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.556197"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2293 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2293 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:33.560741"], ["group_id", 1], ["state", "pending"], ["target_id", 2293], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.560741"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2293 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2293 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2293 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2844) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2844]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.569854"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.569854"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2294 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.575564"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.575564"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2295 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2295 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.582684"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.582684"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2296 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.588616"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.588616"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2297 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.593171"], ["state", "pending"], ["target_id", 2297], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.593171"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2297) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:33.596267"], ["target_id", 2297], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.596267"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2297 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.601462"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.601462"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2298 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.604762"], ["state", "pending"], ["target_id", 2298], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.604762"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2298 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.610241"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.610241"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2299 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.613784"], ["state", "pending"], ["target_id", 2299], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.613784"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2299) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:33.616932"], ["target_id", 2299], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:52:33.616932"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2299 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2299 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.623550"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.623550"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2300 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.629129"], ["state", "pending"], ["target_id", 2300], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.629129"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2300 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2300 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.636147"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.636147"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2301 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.639386"], ["state", "pending"], ["target_id", 2301], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.639386"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2301) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.642491"], ["group_id", 1], ["target_id", 2301], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.642491"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2301 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2301 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.650452"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.650452"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2302 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.653883"], ["state", "pending"], ["target_id", 2302], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.653883"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2302) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:33.657254"], ["target_id", 2302], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.657254"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2302 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2302 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.664627"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.664627"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2303 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.668075"], ["state", "pending"], ["target_id", 2303], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.668075"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2303 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2303 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2851 [["group_id", 1], ["updated_at", "2015-09-28 03:52:33.673607"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2303 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2303 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.681348"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.681348"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2304 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.685004"], ["state", "pending"], ["target_id", 2304], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.685004"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2852]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2304]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2304 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2304 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.693985"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.693985"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2305 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.697312"], ["state", "pending"], ["target_id", 2305], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.697312"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2305) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:33.700304"], ["target_id", 2305], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:52:33.700304"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2853]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2305]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2305 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2305 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.708540"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.708540"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2306 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.712132"], ["state", "pending"], ["target_id", 2306], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.712132"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2306) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.715720"], ["group_id", 1], ["target_id", 2306], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.715720"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2306 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2854]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2306]]  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2306 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.726487"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.726487"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2307 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.730164"], ["state", "pending"], ["target_id", 2307], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.730164"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2307 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2307 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.737352"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.737352"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2308 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.741101"], ["state", "pending"], ["target_id", 2308], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.741101"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2308) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:33.744139"], ["target_id", 2308], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:52:33.744139"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2308 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2308 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.751168"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.751168"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.754831"], ["state", "pending"], ["target_id", 2309], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.754831"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2309) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.758702"], ["group_id", 1], ["target_id", 2309], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.758702"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2309 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.770038"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.770038"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2310 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.775088"], ["state", "pending"], ["target_id", 2310], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.775088"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2310 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '_LIQaHaNJ_Kujau3z4VutAmrUrxPVRyRQ65VFEzTUPpw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.779486"], ["target_id", 2310], ["target_type", "User"], ["token", "_LIQaHaNJ_Kujau3z4VutAmrUrxPVRyRQ65VFEzTUPpw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.779486"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.785142"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.785142"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2311 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.788959"], ["state", "pending"], ["target_id", 2311], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.788959"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2311 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'V4GtrSYEAJEQhKO1xnFMOwj0p9tfeYULQj-r9iBX-m7Q' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.792378"], ["target_id", 2311], ["target_type", "User"], ["token", "V4GtrSYEAJEQhKO1xnFMOwj0p9tfeYULQj-r9iBX-m7Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.792378"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2311 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:33.799204"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:33.799204"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2312 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.802973"], ["state", "pending"], ["target_id", 2312], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.802973"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2312 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '84VufDFkQ97cPv23iaoW6AILIlPYbE2tXVqjyAuq1OLw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.806628"], ["target_id", 2312], ["target_type", "User"], ["token", "84VufDFkQ97cPv23iaoW6AILIlPYbE2tXVqjyAuq1OLw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.806628"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 287 [["active", "f"], ["updated_at", "2015-09-28 03:52:33.809370"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2312 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'GGMyiHLYfRm0ekv4YjQ-OARlJv3DZxlG0VeuySBYKApQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:33.813580"], ["target_id", 2312], ["target_type", "User"], ["token", "GGMyiHLYfRm0ekv4YjQ-OARlJv3DZxlG0VeuySBYKApQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:33.813580"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.044130"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.044130"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2313 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.074280"], ["state", "pending"], ["target_id", 2313], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.074280"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 2313 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.081580"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.081580"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2314 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.084896"], ["state", "pending"], ["target_id", 2314], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.084896"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.088676"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.088676"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2315 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.092169"], ["state", "pending"], ["target_id", 2315], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.092169"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.096319"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.096319"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.099577"], ["state", "pending"], ["target_id", 2316], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.099577"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2316 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2864 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:52:55.102692"]]  (0.7ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.116624"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.116624"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2317 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.120272"], ["state", "pending"], ["target_id", 2317], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.120272"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2317 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2865 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:52:55.126636"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.133182"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.133182"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2318 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.136900"], ["state", "pending"], ["target_id", 2318], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.136900"]]  (0.8ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2318 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2866 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:52:55.143907"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.149313"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.149313"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2319 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.152918"], ["state", "pending"], ["target_id", 2319], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.152918"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2319 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2867 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:52:55.156011"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.161537"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.161537"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2320 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.168260"], ["state", "pending"], ["target_id", 2320], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.168260"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2320 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2868]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.179514"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.179514"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2321 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.182846"], ["state", "pending"], ["target_id", 2321], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.182846"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2321 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2321 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2869 [["state", "sent"], ["updated_at", "2015-09-28 03:52:55.189282"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2321 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2869 [["sent_time", "2015-09-28 03:52:55.190668"], ["updated_at", "2015-09-28 03:52:55.192301"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2869]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.197643"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.197643"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2322 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.201000"], ["state", "pending"], ["target_id", 2322], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.201000"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2322 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:55.204451') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2322 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:55.204451') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2322 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2870]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.213475"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.213475"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2323 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.216883"], ["state", "pending"], ["target_id", 2323], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.216883"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2323 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2323 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:55.221237') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2323 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:55.221237') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2323 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2871]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.230192"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.230192"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2324 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.233412"], ["state", "pending"], ["target_id", 2324], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.233412"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2324 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2324 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:55.237766') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2324 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:55.237766') ORDER BY created_at DESC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2324 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2872]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.246153"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.246153"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.249462"], ["state", "pending"], ["target_id", 2325], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.249462"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2325 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2873)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2873 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:55.255743"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2873]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2325]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2325 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2325]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2873 [["sent_time", "2015-09-28 03:52:55.265499"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:55.268503"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2873]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2325]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2325 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.3ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (3.1ms) NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2325 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.7ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'BoQC4mAzW0zCgl2wemEIJA0D8KEHTv7k627KlMDSV5yA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.318806"], ["target_id", 2325], ["target_type", "User"], ["token", "BoQC4mAzW0zCgl2wemEIJA0D8KEHTv7k627KlMDSV5yA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.318806"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 304.5ms Sent mail to user@example.com (8.7ms) Date: Mon, 28 Sep 2015 13:52:55 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b997906be_1286e3febbc4601f857962@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.598844"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.598844"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2326 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.602784"], ["state", "pending_as_aggregation_parent"], ["target_id", 2326], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.602784"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2326 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.606390"], ["state", "pending"], ["target_id", 2326], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.606390"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.611237"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.611237"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.614864"], ["state", "pending"], ["target_id", 2327], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.614864"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2876 [["state", "sent"], ["updated_at", "2015-09-28 03:52:55.619068"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2876 [["sent_time", "2015-09-28 03:52:55.620537"], ["updated_at", "2015-09-28 03:52:55.622026"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2876]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2327]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2327 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2327 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'IS5rlkVdgq-WSGfgXCZpqQ1Mzvq6tdkNn-X5UXfqT7Pg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.631930"], ["target_id", 2327], ["target_type", "User"], ["token", "IS5rlkVdgq-WSGfgXCZpqQ1Mzvq6tdkNn-X5UXfqT7Pg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.631930"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.1ms Sent mail to user@example.com (1.6ms) Date: Mon, 28 Sep 2015 13:52:55 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b9979b248_1286e3febbc4601f8580d0@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.639789"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.639789"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2328 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.643718"], ["state", "pending"], ["target_id", 2328], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.643718"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2328 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2877 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 03:52:55.649454"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.655892"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.655892"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2329 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.662407"], ["state", "pending"], ["target_id", 2329], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.662407"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2329) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:55.667666"], ["target_id", 2329], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:52:55.667666"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2878]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2329]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2329 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2329 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.6ms) ROLLBACK  (0.3ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.681627"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.681627"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2330 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.684952"], ["state", "pending"], ["target_id", 2330], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.684952"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2879]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2330]]  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2330 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2330 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.694403"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.694403"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2331 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.697581"], ["state", "pending"], ["target_id", 2331], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.697581"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2331 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2331 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2880 [["state", "sent"], ["updated_at", "2015-09-28 03:52:55.702341"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2331 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2880 [["sent_time", "2015-09-28 03:52:55.703537"], ["updated_at", "2015-09-28 03:52:55.704877"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2880]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2331]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2331 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2331 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2331 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'KT5lZyKhGXZ72sAQhPZlVQxLmZ0fvT8Qv3r-v6MwhO9Q' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.713332"], ["target_id", 2331], ["target_type", "User"], ["token", "KT5lZyKhGXZ72sAQhPZlVQxLmZ0fvT8Qv3r-v6MwhO9Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.713332"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.7ms Sent mail to user@example.com (1.9ms) Date: Mon, 28 Sep 2015 13:52:55 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b997af10c_1286e3febbc4601f85815@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.721096"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.721096"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2332 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.724327"], ["state", "pending"], ["target_id", 2332], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.724327"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2881]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2332]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2332 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2332 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.732461"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.732461"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2333 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.735721"], ["state", "pending"], ["target_id", 2333], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.735721"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2882]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2333]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2333 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2333]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2333 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2882 [["sent_time", "2015-09-28 03:52:55.741130"], ["state", "sent"], ["updated_at", "2015-09-28 03:52:55.743592"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2333 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.749564"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.749564"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2334 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.752656"], ["state", "pending"], ["target_id", 2334], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.752656"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2334 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.756315"], ["state", "pending"], ["target_id", 2334], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.756315"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2884]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2334]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2334 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2334]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2334 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2884 [["sent_time", "2015-09-28 03:52:55.760432"], ["state", "sent"], ["updated_at", "2015-09-28 03:52:55.762834"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2334]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2334 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2883 [["sent_time", "2015-09-28 03:52:55.764631"], ["state", "sent"], ["updated_at", "2015-09-28 03:52:55.767413"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2334 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2334 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.776102"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.776102"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2335 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.779503"], ["state", "read"], ["target_id", 2335], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.779503"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2885]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2335]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2335 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.786944"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.786944"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2336 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2336 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.792476"], ["group_id", 2], ["state", "pending"], ["target_id", 2336], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.792476"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2886]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2336]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2336 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2336]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2336 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2336 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2886 [["sent_time", "2015-09-28 03:52:55.798318"], ["state", "sent"], ["updated_at", "2015-09-28 03:52:55.802175"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2336 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2336 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2886]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2336]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2336 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2336 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2336 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2336 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Ds2ngPFm8hetxXQMRBOblQM1hGwbp-Ga0PcdAXV89t3g' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:55.817426"], ["target_id", 2336], ["target_type", "User"], ["token", "Ds2ngPFm8hetxXQMRBOblQM1hGwbp-Ga0PcdAXV89t3g"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.817426"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.8ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 13:52:55 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b997c8795_1286e3febbc4601f85823e@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.7ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.830100"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.830100"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2337 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2337 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.834635"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2337], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.834635"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2337 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2337 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2887 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:55.839978"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2337 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2337 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2887 [["sent_time", "2015-09-28 03:52:55.841918"], ["updated_at", "2015-09-28 03:52:55.844463"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2887]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.851408"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.851408"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2338 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2338 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.856161"], ["group_id", 1], ["state", "pending"], ["target_id", 2338], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.856161"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2338 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2888) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.862287"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.862287"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.867287"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2339], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.867287"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2339 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.871875"], ["group_id", 1], ["state", "pending"], ["target_id", 2339], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.871875"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2339 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2890) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.4ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.877796"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.877796"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.882452"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2340], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.882452"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.886766"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2340], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.886766"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2340 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.891746"], ["group_id", 1], ["state", "pending"], ["target_id", 2340], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.891746"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2340 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2893) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.897406"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.897406"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2341 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2341 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.901744"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 2341], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.901744"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2341 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2341 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.905966"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 2341], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.905966"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2341 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2341 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.910070"], ["group_id", 1], ["state", "pending"], ["target_id", 2341], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.910070"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2341 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2896) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.915555"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.915555"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2342 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2342 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.919825"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2342], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.919825"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2342 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2342 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.924417"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2342], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.924417"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2342 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2342 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.928831"], ["group_id", 1], ["state", "pending"], ["target_id", 2342], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.928831"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2342 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2899) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.935402"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.935402"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2343 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2343 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 17:52:55.936610"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2343], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.942133"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2343 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:55.944334') NewPostNotification Load (1.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2343 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:55.944334') ORDER BY created_at DESC LIMIT 1  (0.4ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2343 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2343 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:52:55.952443"], ["group_id", 1], ["parent_id", 2900], ["state", "pending"], ["target_id", 2343], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.952443"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.959873"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.959873"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2344 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2344 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:52:55.962186"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2344], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.965408"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2344 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:55.967450')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2344 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2344 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.971284"], ["group_id", 1], ["state", "pending"], ["target_id", 2344], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.971284"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.975439"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.975439"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2345 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2345 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:52:55.976704"], ["group_id", 1], ["state", "pending"], ["target_id", 2345], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.980322"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2345 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:55.982718')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2345 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2345 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.986527"], ["group_id", 1], ["state", "pending"], ["target_id", 2345], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.986527"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:55.991446"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:55.991446"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2346 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2346 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:55.995645"], ["group_id", 1], ["state", "pending"], ["target_id", 2346], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:55.995645"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2346 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2906) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2346 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2906) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.002832"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.002832"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.007137"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2347], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.007137"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2907 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.011242"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2907 [["sent_time", "2015-09-28 03:52:56.012400"], ["updated_at", "2015-09-28 03:52:56.014733"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2347 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.018834"], ["group_id", 1], ["state", "pending"], ["target_id", 2347], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.018834"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2347 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2908) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2347 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2908) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.025849"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.025849"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2348 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2348 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.030353"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2348], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.030353"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2348 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2348 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2909 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.034287"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2348 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2348 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2909 [["sent_time", "2015-09-28 03:52:56.035458"], ["updated_at", "2015-09-28 03:52:56.037794"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2348 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2348 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.042969"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2348], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.042969"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2348 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2348 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2910 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.046998"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2348 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2348 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2910 [["sent_time", "2015-09-28 03:52:56.048329"], ["updated_at", "2015-09-28 03:52:56.050649"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2348 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2348 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.054862"], ["group_id", 1], ["state", "pending"], ["target_id", 2348], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.054862"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2348 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2911) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2348 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2911) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.062615"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.062615"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.067055"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2349], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.067055"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2912 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.071208"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2912 [["sent_time", "2015-09-28 03:52:56.072356"], ["updated_at", "2015-09-28 03:52:56.074867"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.079654"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2349], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.079654"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2913 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.083843"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2913 [["sent_time", "2015-09-28 03:52:56.085313"], ["updated_at", "2015-09-28 03:52:56.087855"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.092963"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2349], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.092963"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2914 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.097045"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2914 [["sent_time", "2015-09-28 03:52:56.098123"], ["updated_at", "2015-09-28 03:52:56.100457"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.105430"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2349], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.105430"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2915 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.110681"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2915 [["sent_time", "2015-09-28 03:52:56.111859"], ["updated_at", "2015-09-28 03:52:56.114451"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.118704"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2349], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.118704"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2916 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.122732"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2916 [["sent_time", "2015-09-28 03:52:56.123864"], ["updated_at", "2015-09-28 03:52:56.126320"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.130747"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2349], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.130747"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2917 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.135015"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2917 [["sent_time", "2015-09-28 03:52:56.136141"], ["updated_at", "2015-09-28 03:52:56.138437"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.142540"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2349], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.142540"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2918 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.146459"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2918 [["sent_time", "2015-09-28 03:52:56.147716"], ["updated_at", "2015-09-28 03:52:56.150183"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.154927"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2349], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.154927"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2919 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.158891"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2919 [["sent_time", "2015-09-28 03:52:56.160055"], ["updated_at", "2015-09-28 03:52:56.162485"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.167104"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2349], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.167104"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2920 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.171346"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.8ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2920 [["sent_time", "2015-09-28 03:52:56.172428"], ["updated_at", "2015-09-28 03:52:56.174919"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.179992"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2349], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.179992"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2921 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.184321"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2921 [["sent_time", "2015-09-28 03:52:56.185462"], ["updated_at", "2015-09-28 03:52:56.187812"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.192134"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2349], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.192134"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2922 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.196177"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2922 [["sent_time", "2015-09-28 03:52:56.197305"], ["updated_at", "2015-09-28 03:52:56.199775"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2349 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.204241"], ["group_id", 1], ["state", "pending"], ["target_id", 2349], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.204241"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2349 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2923) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2349 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2923) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.212034"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.212034"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2350 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2350 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.216363"], ["group_id", 1], ["state", "pending"], ["target_id", 2350], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.216363"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2350 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2350 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2350 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2924)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2350 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2350 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2924 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.227872"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.232637"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.232637"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2351 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2351 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.236933"], ["group_id", 1], ["state", "pending"], ["target_id", 2351], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.236933"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2351 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2351 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2351 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2925)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2351 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2351 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2925 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.249596"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.260994"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.260994"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2352 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2352 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.266088"], ["group_id", 1], ["state", "pending"], ["target_id", 2352], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.266088"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2352 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2352 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2352 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2926)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2352 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2352 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2926 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.274934"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2926]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.281259"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.281259"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2353 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2353 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.285829"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2353], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.285829"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2353 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2353 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:54:56.285829"], ["group_id", 1], ["state", "pending"], ["target_id", 2353], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.290708"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2353 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2353 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2353 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2928)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2353 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2353 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2928 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:52:56.300434"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.9ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.305796"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.305796"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2354 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2354 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.317198"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2354], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.317198"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2354 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:56.319849') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2354 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:52:56.319849') ORDER BY created_at DESC LIMIT 1  (0.5ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2354 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2354 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:54:56.317198"], ["group_id", 1], ["parent_id", 2929], ["state", "pending"], ["target_id", 2354], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.328980"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2930]]  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.334639"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.334639"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2355 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2355 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.9ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.338946"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2355], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.338946"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2355 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2355 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.347747"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2355], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.347747"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2355 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2355 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.352404"], ["group_id", 1], ["state", "pending"], ["target_id", 2355], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.352404"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2355 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2355 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2355 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2933)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.361870"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.361870"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2356 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2356 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.366628"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2356], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.366628"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2356 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2356 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.371315"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2356], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.371315"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2356 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2356 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:52:56.376820"], ["group_id", 1], ["state", "pending"], ["target_id", 2356], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.376820"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2356 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2356 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2356 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 2936) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2936]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.386324"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.386324"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2357 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.392965"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.392965"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2358 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2358 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.401607"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.401607"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2359 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.409681"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.409681"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2360 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.413174"], ["state", "pending"], ["target_id", 2360], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.413174"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2360) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:56.416228"], ["target_id", 2360], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.416228"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2360 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.421703"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.421703"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2361 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.425600"], ["state", "pending"], ["target_id", 2361], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.425600"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2361 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.431795"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.431795"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2362 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.435068"], ["state", "pending"], ["target_id", 2362], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.435068"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.5ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2362) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:56.438181"], ["target_id", 2362], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:52:56.438181"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2362 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2362 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.5ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.452733"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.452733"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2363 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.457766"], ["state", "pending"], ["target_id", 2363], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.457766"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2363 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2363 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.464918"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.464918"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2364 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.469615"], ["state", "pending"], ["target_id", 2364], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.469615"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2364) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.473459"], ["group_id", 1], ["target_id", 2364], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.473459"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2364 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2364 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.483048"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.483048"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2365 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.1ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.487123"], ["state", "pending"], ["target_id", 2365], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.487123"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (1.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2365) LIMIT 1 SQL (1.1ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:56.497014"], ["target_id", 2365], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.497014"]]  (0.6ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2365 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2365 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.513173"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.513173"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2366 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.516541"], ["state", "pending"], ["target_id", 2366], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.516541"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2366 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2366 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2943 [["group_id", 1], ["updated_at", "2015-09-28 03:52:56.520765"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2366 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2366 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.528620"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.528620"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2367 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.532021"], ["state", "pending"], ["target_id", 2367], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.532021"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2944]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2367]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2367 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2367 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.540756"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.540756"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2368 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.544153"], ["state", "pending"], ["target_id", 2368], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.544153"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2368) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:56.547749"], ["target_id", 2368], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:52:56.547749"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2945]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2368]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2368 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2368 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.559208"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.559208"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2369 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.562740"], ["state", "pending"], ["target_id", 2369], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.562740"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2369) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.565844"], ["group_id", 1], ["target_id", 2369], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.565844"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2369 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2946]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2369]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2369 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.576027"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.576027"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2370 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.579512"], ["state", "pending"], ["target_id", 2370], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.579512"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2370 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2370 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.586358"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.586358"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2371 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.589792"], ["state", "pending"], ["target_id", 2371], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.589792"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2371) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:52:56.593244"], ["target_id", 2371], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:52:56.593244"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2371 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2371 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.599927"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.599927"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2372 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.603389"], ["state", "pending"], ["target_id", 2372], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.603389"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2372) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.607205"], ["group_id", 1], ["target_id", 2372], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.607205"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2372 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2372 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.615509"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.615509"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2373 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.619813"], ["state", "pending"], ["target_id", 2373], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.619813"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2373 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ZYVJL3nGV4sPQXFhtmXzBgSo4xHSJNDTdCD1e3Gicsig' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.624480"], ["target_id", 2373], ["target_type", "User"], ["token", "ZYVJL3nGV4sPQXFhtmXzBgSo4xHSJNDTdCD1e3Gicsig"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.624480"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.631319"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.631319"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2374 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.636143"], ["state", "pending"], ["target_id", 2374], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.636143"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2374 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'jn0Z4-6OTEiA1naf8_MeugzZYboY0y5wOpj4oGmJO3nQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.639965"], ["target_id", 2374], ["target_type", "User"], ["token", "jn0Z4-6OTEiA1naf8_MeugzZYboY0y5wOpj4oGmJO3nQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.639965"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2374 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:52:56.647246"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:52:56.647246"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2375 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.650869"], ["state", "pending"], ["target_id", 2375], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.650869"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2375 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.6ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'HCmuCOvER7z3SklJSq6m7AcdaP8J05tpOgZQbhOnjqrQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.654702"], ["target_id", 2375], ["target_type", "User"], ["token", "HCmuCOvER7z3SklJSq6m7AcdaP8J05tpOgZQbhOnjqrQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.654702"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 295 [["active", "f"], ["updated_at", "2015-09-28 03:52:56.658572"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2375 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'zw66XvWMamCNunyNiWRoGA1r7PN9iImV4AxqqKmBQhMQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:52:56.661902"], ["target_id", 2375], ["target_type", "User"], ["token", "zw66XvWMamCNunyNiWRoGA1r7PN9iImV4AxqqKmBQhMQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:52:56.661902"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:39.873375"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:39.873375"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.9ms) SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2376 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:39.908747"], ["state", "pending"], ["target_id", 2376], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:39.908747"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 2376 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:39.917096"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:39.917096"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2377 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:39.921016"], ["state", "pending"], ["target_id", 2377], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:39.921016"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:39.925409"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:39.925409"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (1.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2378 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:39.930724"], ["state", "pending"], ["target_id", 2378], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:39.930724"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:39.937778"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:39.937778"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2379 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:39.941529"], ["state", "pending"], ["target_id", 2379], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:39.941529"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2379 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2956 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:53:39.944570"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:39.954021"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:39.954021"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2380 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:39.957601"], ["state", "pending"], ["target_id", 2380], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:39.957601"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2380 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.8ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2957 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:53:39.960693"]]  (0.4ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.9ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.5ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:39.971604"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:39.971604"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2381 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:39.975046"], ["state", "pending"], ["target_id", 2381], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:39.975046"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2381 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2958 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:53:39.978548"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:39.984028"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:39.984028"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2382 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:39.987788"], ["state", "pending"], ["target_id", 2382], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:39.987788"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2382 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2959 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:53:39.990798"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.8ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:39.997934"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:39.997934"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2383 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.005103"], ["state", "pending"], ["target_id", 2383], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.005103"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2383 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2960]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.014751"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.014751"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2384 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.019074"], ["state", "pending"], ["target_id", 2384], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.019074"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2384 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2384 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2961 [["state", "sent"], ["updated_at", "2015-09-28 03:53:40.025415"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2384 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2961 [["sent_time", "2015-09-28 03:53:40.026995"], ["updated_at", "2015-09-28 03:53:40.028805"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2961]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.035375"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.035375"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2385 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.039610"], ["state", "pending"], ["target_id", 2385], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.039610"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2385 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:40.045009') NewPostNotification Load (1.9ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2385 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:40.045009') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2385 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2962]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.057968"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.057968"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2386 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (1.0ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.061347"], ["state", "pending"], ["target_id", 2386], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.061347"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2386 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2386 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:40.072169') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2386 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:40.072169') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2386 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.9ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2963]]  (0.6ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.084457"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.084457"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2387 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.088105"], ["state", "pending"], ["target_id", 2387], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.088105"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2387 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2387 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:40.092512') NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2387 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:40.092512') ORDER BY created_at DESC LIMIT 1  (0.4ms) SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2387 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2964]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.106224"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.106224"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2388 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.109747"], ["state", "pending"], ["target_id", 2388], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.109747"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2388 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2388 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2965)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2388 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2965 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.117590"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2965]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2388]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2388 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2388]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2388 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2965 [["sent_time", "2015-09-28 03:53:40.127310"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.130293"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2388 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2965]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2388]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2388 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2388 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.5ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (3.5ms) NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2388 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.5ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'WIDPi8IHJxBiqXkKI4u-RgvX9SeLz5emgIUJZY2qJWkw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.175951"], ["target_id", 2388], ["target_type", "User"], ["token", "WIDPi8IHJxBiqXkKI4u-RgvX9SeLz5emgIUJZY2qJWkw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.175951"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 186.1ms Sent mail to user@example.com (6.1ms) Date: Mon, 28 Sep 2015 13:53:40 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b9c450c8a_12a923fdf71c601fc4179a@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.336498"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.336498"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2389 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.340014"], ["state", "pending_as_aggregation_parent"], ["target_id", 2389], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.340014"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2389 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.343169"], ["state", "pending"], ["target_id", 2389], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.343169"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2389 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2389 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 2967)  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.350849"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.350849"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2390 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.355121"], ["state", "pending"], ["target_id", 2390], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.355121"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2390 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2390 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2968 [["state", "sent"], ["updated_at", "2015-09-28 03:53:40.359237"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2390 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2968 [["sent_time", "2015-09-28 03:53:40.360467"], ["updated_at", "2015-09-28 03:53:40.361898"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2968]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2390]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2390 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2390 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.3ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2390 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'KP8tRpIfQdnzGyluTPDM5AUkQcR_R4SBbPRUU-krAL6w' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.371789"], ["target_id", 2390], ["target_type", "User"], ["token", "KP8tRpIfQdnzGyluTPDM5AUkQcR_R4SBbPRUU-krAL6w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.371789"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.6ms Sent mail to user@example.com (1.9ms) Date: Mon, 28 Sep 2015 13:53:40 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b9c45bb74_12a923fdf71c601fc4187a@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.380668"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.380668"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2391 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.384341"], ["state", "pending"], ["target_id", 2391], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.384341"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2391 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2969 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 03:53:40.387590"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.392098"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.392098"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2392 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.395937"], ["state", "pending"], ["target_id", 2392], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.395937"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2392) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:53:40.401917"], ["target_id", 2392], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:53:40.401917"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2970]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2392]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2392 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2392 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.411088"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.411088"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2393 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.419861"], ["state", "pending"], ["target_id", 2393], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.419861"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2971]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2393]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2393 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2393 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.429671"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.429671"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2394 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.433434"], ["state", "pending"], ["target_id", 2394], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.433434"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2394 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2394 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2972 [["state", "sent"], ["updated_at", "2015-09-28 03:53:40.438272"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2394 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2972 [["sent_time", "2015-09-28 03:53:40.439583"], ["updated_at", "2015-09-28 03:53:40.441027"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2972]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2394]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2394 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2394 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.1ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.6ms) NotifyUser::UserHash Load (1.1ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2394 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.4ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '9LrArk0jbyGGQdUxdyLpGgDsCYNl8wIc1GkLs4sf8F2Q' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.453156"], ["target_id", 2394], ["target_type", "User"], ["token", "9LrArk0jbyGGQdUxdyLpGgDsCYNl8wIc1GkLs4sf8F2Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.453156"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 10.5ms Sent mail to user@example.com (2.3ms) Date: Mon, 28 Sep 2015 13:53:40 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b9c46fcee_12a923fdf71c601fc419ab@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.462768"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.462768"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2395 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.467593"], ["state", "pending"], ["target_id", 2395], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.467593"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2973]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2395]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2395 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2395 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.479845"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.479845"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2396 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.483716"], ["state", "pending"], ["target_id", 2396], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.483716"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2974]] User Load (0.8ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2396]] NewPostNotification Load (1.0ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2396 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.4ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2396]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2396 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2974 [["sent_time", "2015-09-28 03:53:40.493804"], ["state", "sent"], ["updated_at", "2015-09-28 03:53:40.497405"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2396 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.503991"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.503991"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2397 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.507452"], ["state", "pending"], ["target_id", 2397], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.507452"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2397 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.511099"], ["state", "pending"], ["target_id", 2397], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.511099"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2976]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2397]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2397 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2397]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2397 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2976 [["sent_time", "2015-09-28 03:53:40.516065"], ["state", "sent"], ["updated_at", "2015-09-28 03:53:40.518497"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2397]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2397 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2975 [["sent_time", "2015-09-28 03:53:40.520270"], ["state", "sent"], ["updated_at", "2015-09-28 03:53:40.522893"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2397 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2397 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.532579"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.532579"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2398 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.536016"], ["state", "read"], ["target_id", 2398], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.536016"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2977]] User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2398]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2398 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.544093"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.544093"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.549130"], ["group_id", 2], ["state", "pending"], ["target_id", 2399], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.549130"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2978]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2399]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2399 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2399]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 2978 [["sent_time", "2015-09-28 03:53:40.554677"], ["state", "sent"], ["updated_at", "2015-09-28 03:53:40.558150"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2978]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2399]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2399 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.3ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2399 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'o0ZiwRbYk8XPkO9VPM7U3ANQ1Ce_o_hZLLSEB9ON3Ovw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:40.571931"], ["target_id", 2399], ["target_type", "User"], ["token", "o0ZiwRbYk8XPkO9VPM7U3ANQ1Ce_o_hZLLSEB9ON3Ovw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.571931"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.0ms Sent mail to user@example.com (1.9ms) Date: Mon, 28 Sep 2015 13:53:40 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b9c48c823_12a923fdf71c601fc42071@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.581197"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.581197"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2400 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2400 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.586051"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2400], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.586051"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2400 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2400 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2979 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.590565"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2400 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2400 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2979 [["sent_time", "2015-09-28 03:53:40.591790"], ["updated_at", "2015-09-28 03:53:40.594474"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 2979]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.601849"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.601849"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2401 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2401 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.606720"], ["group_id", 1], ["state", "pending"], ["target_id", 2401], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.606720"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2401 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2980) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.613227"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.613227"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2402 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2402 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.617859"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2402], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.617859"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2402 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2402 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.622203"], ["group_id", 1], ["state", "pending"], ["target_id", 2402], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.622203"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2402 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2982) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.629220"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.629220"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2403 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2403 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.634149"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2403], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.634149"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2403 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2403 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.638438"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2403], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.638438"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2403 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2403 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.642639"], ["group_id", 1], ["state", "pending"], ["target_id", 2403], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.642639"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2403 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2985) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.7ms) SAVEPOINT active_record_1 SQL (1.0ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.651679"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.651679"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2404 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2404 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.661762"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 2404], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.661762"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2404 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (2.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2404 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.672450"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 2404], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.672450"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2404 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2404 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.683083"], ["group_id", 1], ["state", "pending"], ["target_id", 2404], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.683083"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2404 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2988) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.692622"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.692622"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2405 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2405 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.701185"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2405], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.701185"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2405 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2405 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.705869"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2405], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.705869"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2405 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2405 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.710483"], ["group_id", 1], ["state", "pending"], ["target_id", 2405], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.710483"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2405 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2991) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.5ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.721459"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.721459"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2406 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2406 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 17:53:40.722691"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2406], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.726232"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2406 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:40.728840') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2406 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:40.728840') ORDER BY created_at DESC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2406 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2406 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:53:40.734854"], ["group_id", 1], ["parent_id", 2992], ["state", "pending"], ["target_id", 2406], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.734854"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.739044"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.739044"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2407 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2407 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:53:40.740130"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2407], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.744298"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2407 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:40.746418')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2407 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2407 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.750444"], ["group_id", 1], ["state", "pending"], ["target_id", 2407], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.750444"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.754336"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.754336"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2408 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2408 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:53:40.755467"], ["group_id", 1], ["state", "pending"], ["target_id", 2408], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.758986"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2408 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:40.761324')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2408 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2408 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.765283"], ["group_id", 1], ["state", "pending"], ["target_id", 2408], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.765283"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.769955"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.769955"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2409 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2409 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.774749"], ["group_id", 1], ["state", "pending"], ["target_id", 2409], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.774749"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2409 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2998) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2409 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 2998) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.782351"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.782351"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.786753"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2410], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.786753"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2999 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.790669"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 2999 [["sent_time", "2015-09-28 03:53:40.791814"], ["updated_at", "2015-09-28 03:53:40.794432"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2410 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.799206"], ["group_id", 1], ["state", "pending"], ["target_id", 2410], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.799206"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2410 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3000) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2410 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3000) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.806228"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.806228"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.810484"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.810484"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3001 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.814385"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3001 [["sent_time", "2015-09-28 03:53:40.815796"], ["updated_at", "2015-09-28 03:53:40.818396"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.823308"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.823308"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3002 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.827560"]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3002 [["sent_time", "2015-09-28 03:53:40.829265"], ["updated_at", "2015-09-28 03:53:40.834374"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2411 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.841715"], ["group_id", 1], ["state", "pending"], ["target_id", 2411], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.841715"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2411 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3003) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2411 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3003) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.6ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:40.853783"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:40.853783"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.858551"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2412], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.858551"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3004 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.862623"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3004 [["sent_time", "2015-09-28 03:53:40.863743"], ["updated_at", "2015-09-28 03:53:40.866165"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.870656"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2412], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.870656"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3005 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.874802"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3005 [["sent_time", "2015-09-28 03:53:40.875945"], ["updated_at", "2015-09-28 03:53:40.878819"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.883411"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2412], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.883411"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3006 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.888899"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3006 [["sent_time", "2015-09-28 03:53:40.890060"], ["updated_at", "2015-09-28 03:53:40.892650"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.898088"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2412], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.898088"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3007 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.902143"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3007 [["sent_time", "2015-09-28 03:53:40.903270"], ["updated_at", "2015-09-28 03:53:40.905644"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.910050"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2412], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.910050"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3008 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.914017"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3008 [["sent_time", "2015-09-28 03:53:40.915116"], ["updated_at", "2015-09-28 03:53:40.917673"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.922150"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2412], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.922150"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3009 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.926211"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3009 [["sent_time", "2015-09-28 03:53:40.927367"], ["updated_at", "2015-09-28 03:53:40.929833"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.934286"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2412], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.934286"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3010 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.938262"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3010 [["sent_time", "2015-09-28 03:53:40.939474"], ["updated_at", "2015-09-28 03:53:40.942167"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.946593"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2412], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.946593"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3011 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.950724"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3011 [["sent_time", "2015-09-28 03:53:40.951838"], ["updated_at", "2015-09-28 03:53:40.954145"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.958630"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2412], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.958630"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3012 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.962432"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3012 [["sent_time", "2015-09-28 03:53:40.963537"], ["updated_at", "2015-09-28 03:53:40.966365"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.971591"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2412], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.971591"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3013 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.975901"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3013 [["sent_time", "2015-09-28 03:53:40.977103"], ["updated_at", "2015-09-28 03:53:40.982621"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:40.987286"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2412], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:40.987286"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3014 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:40.991338"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.8ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3014 [["sent_time", "2015-09-28 03:53:40.992425"], ["updated_at", "2015-09-28 03:53:40.995113"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2412 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:41.004127"], ["group_id", 1], ["state", "pending"], ["target_id", 2412], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.004127"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2412 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3015) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2412 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3015) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.012281"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.012281"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:41.016877"], ["group_id", 1], ["state", "pending"], ["target_id", 2413], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.016877"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2413 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3016)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2413 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3016 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:41.026819"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.031847"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.031847"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2414 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2414 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:41.036372"], ["group_id", 1], ["state", "pending"], ["target_id", 2414], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.036372"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2414 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2414 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2414 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3017)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2414 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2414 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3017 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:41.050185"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.055510"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.055510"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:41.060387"], ["group_id", 1], ["state", "pending"], ["target_id", 2415], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.060387"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2415 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3018)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2415 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3018 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:41.071015"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3018]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.077785"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.077785"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2416 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2416 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:41.082616"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2416], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.082616"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2416 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2416 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:55:41.082616"], ["group_id", 1], ["state", "pending"], ["target_id", 2416], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.087611"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2416 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2416 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2416 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3020)  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2416 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2416 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3020 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:41.097707"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.103818"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.103818"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2417 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2417 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:41.109526"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2417], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.109526"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2417 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:41.112853') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2417 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:41.112853') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2417 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2417 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:55:41.109526"], ["group_id", 1], ["parent_id", 3021], ["state", "pending"], ["target_id", 2417], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.120103"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3022]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.126449"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.126449"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:41.134331"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2418], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.134331"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:41.139168"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2418], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.139168"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:41.143553"], ["group_id", 1], ["state", "pending"], ["target_id", 2418], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.143553"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2418 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2418 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3025)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.157061"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.157061"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2419 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2419 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:41.161992"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2419], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.161992"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2419 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2419 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:41.168128"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2419], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.168128"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2419 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2419 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:41.172988"], ["group_id", 1], ["state", "pending"], ["target_id", 2419], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.172988"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2419 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2419 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2419 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3028) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3028]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.184011"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.184011"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2420 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.190513"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.190513"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2421 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2421 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.198976"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.198976"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2422 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.206575"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.206575"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2423 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.210873"], ["state", "pending"], ["target_id", 2423], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.210873"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2423) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:53:41.217357"], ["target_id", 2423], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.217357"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2423 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.223021"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.223021"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2424 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.226478"], ["state", "pending"], ["target_id", 2424], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.226478"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2424 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.4ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.235965"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.235965"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2425 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.239994"], ["state", "pending"], ["target_id", 2425], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.239994"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2425) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:53:41.243032"], ["target_id", 2425], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:53:41.243032"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2425 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2425 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.250103"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.250103"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2426 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.254084"], ["state", "pending"], ["target_id", 2426], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.254084"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2426 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2426 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.261413"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.261413"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2427 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.267430"], ["state", "pending"], ["target_id", 2427], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.267430"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2427) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.270680"], ["group_id", 1], ["target_id", 2427], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.270680"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2427 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2427 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.279004"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.279004"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2428 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.282834"], ["state", "pending"], ["target_id", 2428], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.282834"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2428) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:53:41.285969"], ["target_id", 2428], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.285969"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2428 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2428 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.293534"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.293534"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2429 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.297092"], ["state", "pending"], ["target_id", 2429], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.297092"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2429 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2429 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3035 [["group_id", 1], ["updated_at", "2015-09-28 03:53:41.302019"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2429 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2429 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.308918"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.308918"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2430 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.313351"], ["state", "pending"], ["target_id", 2430], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.313351"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3036]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2430]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2430 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2430 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.323213"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.323213"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2431 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.326661"], ["state", "pending"], ["target_id", 2431], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.326661"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2431) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:53:41.329436"], ["target_id", 2431], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:53:41.329436"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3037]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2431]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2431 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2431 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.338186"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.338186"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2432 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.341809"], ["state", "pending"], ["target_id", 2432], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.341809"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2432) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.344941"], ["group_id", 1], ["target_id", 2432], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.344941"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2432 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3038]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2432]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2432 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.355264"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.355264"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2433 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.358942"], ["state", "pending"], ["target_id", 2433], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.358942"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2433 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2433 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.367118"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.367118"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2434 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.370719"], ["state", "pending"], ["target_id", 2434], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.370719"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2434) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:53:41.374638"], ["target_id", 2434], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:53:41.374638"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2434 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2434 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.381850"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.381850"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2435 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.385618"], ["state", "pending"], ["target_id", 2435], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.385618"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2435) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.388857"], ["group_id", 1], ["target_id", 2435], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.388857"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2435 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2435 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.396980"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.396980"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2436 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.401731"], ["state", "pending"], ["target_id", 2436], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.401731"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2436 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'mxs0dEoLo8OvZjRtcdpTjwQKbupc4o1GY9rpLTlvaqAA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.406129"], ["target_id", 2436], ["target_type", "User"], ["token", "mxs0dEoLo8OvZjRtcdpTjwQKbupc4o1GY9rpLTlvaqAA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.406129"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.412771"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.412771"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2437 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.417356"], ["state", "pending"], ["target_id", 2437], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.417356"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2437 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'GUym5Idryt-BZIiEC1wgvwlD4NZ4Y1-5M8AHFKdJWeeA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.420847"], ["target_id", 2437], ["target_type", "User"], ["token", "GUym5Idryt-BZIiEC1wgvwlD4NZ4Y1-5M8AHFKdJWeeA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.420847"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2437 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:41.427973"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:41.427973"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2438 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.431979"], ["state", "pending"], ["target_id", 2438], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.431979"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2438 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'QB8aHTEDct8CB0e5D3IGrgV47w-9HS1IDgGI0U0lzYVA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.436414"], ["target_id", 2438], ["target_type", "User"], ["token", "QB8aHTEDct8CB0e5D3IGrgV47w-9HS1IDgGI0U0lzYVA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.436414"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 303 [["active", "f"], ["updated_at", "2015-09-28 03:53:41.439337"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2438 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'kdkdfnhGBzX_pR3FKlhO6QXyUX_AbK-fuVgtHi5WHcUA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:41.442568"], ["target_id", 2438], ["target_type", "User"], ["token", "kdkdfnhGBzX_pR3FKlhO6QXyUX_AbK-fuVgtHi5WHcUA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:41.442568"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.8ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:54.792028"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:54.792028"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2439 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:54.834791"], ["state", "pending"], ["target_id", 2439], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:54.834791"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 2439 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:54.842605"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:54.842605"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2440 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:54.846163"], ["state", "pending"], ["target_id", 2440], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:54.846163"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:54.850407"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:54.850407"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2441 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:54.853847"], ["state", "pending"], ["target_id", 2441], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:54.853847"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:54.858059"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:54.858059"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2442 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:54.861382"], ["state", "pending"], ["target_id", 2442], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:54.861382"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2442 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3048 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:53:54.864503"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:54.873354"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:54.873354"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2443 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:54.876985"], ["state", "pending"], ["target_id", 2443], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:54.876985"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2443 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3049 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:53:54.880571"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:54.886779"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:54.886779"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2444 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:54.892323"], ["state", "pending"], ["target_id", 2444], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:54.892323"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2444 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3050 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:53:54.895546"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:54.900927"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:54.900927"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2445 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:54.904186"], ["state", "pending"], ["target_id", 2445], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:54.904186"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2445 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3051 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:53:54.907145"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:54.913003"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:54.913003"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2446 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:54.916965"], ["state", "pending"], ["target_id", 2446], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:54.916965"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2446 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3052]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:54.924651"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:54.924651"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2447 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:54.928484"], ["state", "pending"], ["target_id", 2447], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:54.928484"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2447 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2447 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3053 [["state", "sent"], ["updated_at", "2015-09-28 03:53:54.933344"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2447 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3053 [["sent_time", "2015-09-28 03:53:54.934656"], ["updated_at", "2015-09-28 03:53:54.937113"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3053]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:54.943062"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:54.943062"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2448 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:54.946488"], ["state", "pending"], ["target_id", 2448], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:54.946488"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2448 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:54.949703') NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2448 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:54.949703') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2448 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3054]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:54.958900"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:54.958900"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2449 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:54.962298"], ["state", "pending"], ["target_id", 2449], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:54.962298"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2449 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2449 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:54.967002') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2449 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:54.967002') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2449 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3055]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:54.975404"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:54.975404"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2450 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:54.978981"], ["state", "pending"], ["target_id", 2450], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:54.978981"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2450 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2450 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:54.983632') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2450 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:54.983632') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2450 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3056]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:54.994834"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:54.994834"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2451 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:54.998529"], ["state", "pending"], ["target_id", 2451], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:54.998529"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2451 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2451 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 3057)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2451 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3057 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.004824"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3057]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2451]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2451 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2451]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2451 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3057 [["sent_time", "2015-09-28 03:53:55.015096"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.017902"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2451 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3057]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2451]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2451 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2451 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.3ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (2.8ms) NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2451 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'H-ZY0OJKSpspRy2Ai_UxrQwAIFyhY6CdC08ZG4SMIkyg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.062654"], ["target_id", 2451], ["target_type", "User"], ["token", "H-ZY0OJKSpspRy2Ai_UxrQwAIFyhY6CdC08ZG4SMIkyg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.062654"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 177.7ms Sent mail to user@example.com (5.6ms) Date: Mon, 28 Sep 2015 13:53:55 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b9d33341f_12c7d3fc05a04c1f838846@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.215148"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.215148"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2452 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.218490"], ["state", "pending_as_aggregation_parent"], ["target_id", 2452], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.218490"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2452 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.221635"], ["state", "pending"], ["target_id", 2452], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.221635"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2452 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2452 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 3059)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.229144"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.229144"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2453 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.232245"], ["state", "pending"], ["target_id", 2453], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.232245"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2453 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2453 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3060 [["state", "sent"], ["updated_at", "2015-09-28 03:53:55.236138"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2453 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3060 [["sent_time", "2015-09-28 03:53:55.237356"], ["updated_at", "2015-09-28 03:53:55.238710"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3060]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2453]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2453 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2453 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.3ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2453 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'I1xjDD8uqUbxbGaMSB7ZewOBOcSsXDZm1_6bQ_Gz7sQQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.247627"], ["target_id", 2453], ["target_type", "User"], ["token", "I1xjDD8uqUbxbGaMSB7ZewOBOcSsXDZm1_6bQ_Gz7sQQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.247627"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.1ms Sent mail to user@example.com (3.5ms) Date: Mon, 28 Sep 2015 13:53:55 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b9d33d7ee_12c7d3fc05a04c1f8389ad@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.257614"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.257614"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2454 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.261441"], ["state", "pending"], ["target_id", 2454], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.261441"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2454 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3061 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 03:53:55.264316"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.268319"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.268319"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2455 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.271950"], ["state", "pending"], ["target_id", 2455], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.271950"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2455) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:53:55.277364"], ["target_id", 2455], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:53:55.277364"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3062]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2455]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2455 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2455 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.286556"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.286556"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2456 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.289797"], ["state", "pending"], ["target_id", 2456], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.289797"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3063]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2456]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2456 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2456 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.300532"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.300532"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2457 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.303767"], ["state", "pending"], ["target_id", 2457], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.303767"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2457 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2457 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3064 [["state", "sent"], ["updated_at", "2015-09-28 03:53:55.308142"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2457 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3064 [["sent_time", "2015-09-28 03:53:55.309289"], ["updated_at", "2015-09-28 03:53:55.310624"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3064]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2457]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2457 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2457 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.3ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2457 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'TamRtap3gOEnaVAtzJL7BggbKXf4gswuWu4Myr4PCqCw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.318794"], ["target_id", 2457], ["target_type", "User"], ["token", "TamRtap3gOEnaVAtzJL7BggbKXf4gswuWu4Myr4PCqCw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.318794"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.7ms Sent mail to user@example.com (2.0ms) Date: Mon, 28 Sep 2015 13:53:55 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b9d34eb42_12c7d3fc05a04c1f8390fd@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.326813"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.326813"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2458 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.330627"], ["state", "pending"], ["target_id", 2458], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.330627"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3065]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2458]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2458 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2458 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.341056"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.341056"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2459 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.344381"], ["state", "pending"], ["target_id", 2459], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.344381"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3066]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2459]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2459 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2459]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2459 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3066 [["sent_time", "2015-09-28 03:53:55.348675"], ["state", "sent"], ["updated_at", "2015-09-28 03:53:55.351205"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2459 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.357576"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.357576"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2460 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.360757"], ["state", "pending"], ["target_id", 2460], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.360757"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2460 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.364131"], ["state", "pending"], ["target_id", 2460], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.364131"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3068]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2460]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2460 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2460]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2460 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3068 [["sent_time", "2015-09-28 03:53:55.369106"], ["state", "sent"], ["updated_at", "2015-09-28 03:53:55.371644"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2460]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2460 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3067 [["sent_time", "2015-09-28 03:53:55.373682"], ["state", "sent"], ["updated_at", "2015-09-28 03:53:55.376568"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2460 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2460 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.385614"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.385614"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2461 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.389090"], ["state", "read"], ["target_id", 2461], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.389090"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3069]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2461]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2461 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.396603"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.396603"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2462 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2462 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.401338"], ["group_id", 2], ["state", "pending"], ["target_id", 2462], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.401338"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3070]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2462]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2462 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2462]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2462 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2462 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3070 [["sent_time", "2015-09-28 03:53:55.407014"], ["state", "sent"], ["updated_at", "2015-09-28 03:53:55.410534"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2462 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2462 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3070]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2462]]  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2462 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2462 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2462 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.3ms) NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2462 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'WaB29BBheVEACTX5ZD6rrQX5nbHiY4e2raB2iXgIXS1Q' LIMIT 1 SQL (0.6ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:55.424351"], ["target_id", 2462], ["target_type", "User"], ["token", "WaB29BBheVEACTX5ZD6rrQX5nbHiY4e2raB2iXgIXS1Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.424351"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.8ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 13:53:55 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608b9d368b23_12c7d3fc05a04c1f8391d@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.433061"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.433061"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2463 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2463 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.437859"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2463], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.437859"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2463 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2463 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3071 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.442417"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2463 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2463 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3071 [["sent_time", "2015-09-28 03:53:55.443599"], ["updated_at", "2015-09-28 03:53:55.446140"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3071]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.453114"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.453114"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2464 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2464 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.457492"], ["group_id", 1], ["state", "pending"], ["target_id", 2464], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.457492"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2464 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3072) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.462960"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.462960"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2465 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2465 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.467697"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2465], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.467697"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2465 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2465 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.473610"], ["group_id", 1], ["state", "pending"], ["target_id", 2465], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.473610"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2465 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3074) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.480010"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.480010"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2466 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2466 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.484374"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2466], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.484374"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2466 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2466 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.489086"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2466], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.489086"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2466 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2466 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.493410"], ["group_id", 1], ["state", "pending"], ["target_id", 2466], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.493410"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2466 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3077) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.499457"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.499457"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2467 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2467 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.503763"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 2467], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.503763"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2467 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2467 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.507857"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 2467], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.507857"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2467 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2467 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.512228"], ["group_id", 1], ["state", "pending"], ["target_id", 2467], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.512228"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2467 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3080) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.518316"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.518316"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2468 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2468 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.523805"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2468], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.523805"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2468 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2468 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.528210"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2468], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.528210"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2468 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2468 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.532509"], ["group_id", 1], ["state", "pending"], ["target_id", 2468], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.532509"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2468 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3083) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.538450"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.538450"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2469 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2469 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 17:53:55.539620"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2469], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.542862"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2469 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:55.545013') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2469 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:55.545013') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2469 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2469 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:53:55.550037"], ["group_id", 1], ["parent_id", 3084], ["state", "pending"], ["target_id", 2469], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.550037"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.554481"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.554481"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2470 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2470 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:53:55.555586"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2470], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.559654"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2470 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:55.562296')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2470 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2470 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.566410"], ["group_id", 1], ["state", "pending"], ["target_id", 2470], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.566410"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.570470"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.570470"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2471 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2471 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:53:55.571538"], ["group_id", 1], ["state", "pending"], ["target_id", 2471], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.574818"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2471 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:55.576986')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2471 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2471 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.580925"], ["group_id", 1], ["state", "pending"], ["target_id", 2471], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.580925"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.584879"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.584879"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2472 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2472 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.589315"], ["group_id", 1], ["state", "pending"], ["target_id", 2472], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.589315"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2472 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3090) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2472 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3090) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.596869"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.596869"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2473 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2473 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.601301"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2473], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.601301"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2473 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2473 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3091 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.605749"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2473 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2473 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3091 [["sent_time", "2015-09-28 03:53:55.607007"], ["updated_at", "2015-09-28 03:53:55.610284"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2473 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2473 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.615160"], ["group_id", 1], ["state", "pending"], ["target_id", 2473], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.615160"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2473 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3092) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2473 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3092) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.622337"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.622337"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2474 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2474 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.627446"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2474], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.627446"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2474 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2474 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3093 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.631781"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2474 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2474 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3093 [["sent_time", "2015-09-28 03:53:55.633022"], ["updated_at", "2015-09-28 03:53:55.635394"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2474 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2474 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.639758"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2474], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.639758"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2474 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2474 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3094 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.643828"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2474 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2474 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3094 [["sent_time", "2015-09-28 03:53:55.644963"], ["updated_at", "2015-09-28 03:53:55.647425"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2474 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2474 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.651890"], ["group_id", 1], ["state", "pending"], ["target_id", 2474], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.651890"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2474 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3095) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2474 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3095) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.4ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.661464"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.661464"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.665731"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2475], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.665731"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3096 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.670084"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (3.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.9ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3096 [["sent_time", "2015-09-28 03:53:55.671426"], ["updated_at", "2015-09-28 03:53:55.678469"]]  (0.8ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.690654"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2475], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.690654"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3097 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.695139"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3097 [["sent_time", "2015-09-28 03:53:55.696336"], ["updated_at", "2015-09-28 03:53:55.698676"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.703014"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2475], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.703014"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3098 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.707629"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3098 [["sent_time", "2015-09-28 03:53:55.708848"], ["updated_at", "2015-09-28 03:53:55.711479"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.715821"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2475], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.715821"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3099 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.719746"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3099 [["sent_time", "2015-09-28 03:53:55.721047"], ["updated_at", "2015-09-28 03:53:55.723776"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.729403"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2475], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.729403"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3100 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.733548"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3100 [["sent_time", "2015-09-28 03:53:55.734833"], ["updated_at", "2015-09-28 03:53:55.737299"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.741511"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2475], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.741511"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3101 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.745717"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3101 [["sent_time", "2015-09-28 03:53:55.747002"], ["updated_at", "2015-09-28 03:53:55.749969"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.754599"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2475], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.754599"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3102 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.758814"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3102 [["sent_time", "2015-09-28 03:53:55.760029"], ["updated_at", "2015-09-28 03:53:55.762434"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.767449"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2475], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.767449"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3103 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.772353"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3103 [["sent_time", "2015-09-28 03:53:55.773638"], ["updated_at", "2015-09-28 03:53:55.775936"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.780332"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2475], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.780332"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3104 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.785284"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3104 [["sent_time", "2015-09-28 03:53:55.786499"], ["updated_at", "2015-09-28 03:53:55.788971"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.793233"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2475], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.793233"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3105 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.797335"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3105 [["sent_time", "2015-09-28 03:53:55.798520"], ["updated_at", "2015-09-28 03:53:55.801092"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.805285"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2475], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.805285"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3106 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.808994"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3106 [["sent_time", "2015-09-28 03:53:55.810070"], ["updated_at", "2015-09-28 03:53:55.812369"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2475 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.816732"], ["group_id", 1], ["state", "pending"], ["target_id", 2475], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.816732"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2475 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3107) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2475 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3107) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.825284"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.825284"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2476 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2476 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.830395"], ["group_id", 1], ["state", "pending"], ["target_id", 2476], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.830395"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2476 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2476 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2476 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3108)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2476 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2476 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3108 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.840723"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.845537"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.845537"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2477 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2477 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.850033"], ["group_id", 1], ["state", "pending"], ["target_id", 2477], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.850033"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2477 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2477 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2477 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3109)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2477 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2477 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3109 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.864481"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.869760"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.869760"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2478 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2478 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.875027"], ["group_id", 1], ["state", "pending"], ["target_id", 2478], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.875027"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2478 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2478 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2478 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3110)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2478 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2478 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3110 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.884638"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3110]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.891594"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.891594"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2479 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2479 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.896421"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2479], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.896421"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2479 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2479 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:55:55.896421"], ["group_id", 1], ["state", "pending"], ["target_id", 2479], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.901675"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2479 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2479 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2479 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3112)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2479 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2479 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3112 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:53:55.912406"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.918031"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.918031"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2480 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2480 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.923017"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2480], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.923017"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2480 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:55.925464') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2480 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:53:55.925464') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2480 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2480 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:55:55.923017"], ["group_id", 1], ["parent_id", 3113], ["state", "pending"], ["target_id", 2480], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.931287"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3114]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.937609"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.937609"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2481 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2481 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.942839"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2481], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.942839"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2481 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2481 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.947240"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2481], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.947240"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2481 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2481 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.8ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.952131"], ["group_id", 1], ["state", "pending"], ["target_id", 2481], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.952131"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2481 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2481 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2481 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3117)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.962195"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.962195"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2482 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2482 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.966884"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2482], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.966884"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2482 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2482 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.971241"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2482], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.971241"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2482 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2482 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:53:55.975515"], ["group_id", 1], ["state", "pending"], ["target_id", 2482], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:55.975515"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2482 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2482 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2482 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3120) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3120]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.984821"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.984821"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2483 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.990899"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.990899"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2484 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2484 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:55.998613"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:55.998613"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2485 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.005665"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.005665"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2486 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.009427"], ["state", "pending"], ["target_id", 2486], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.009427"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2486) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:53:56.012819"], ["target_id", 2486], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.012819"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2486 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.018056"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.018056"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2487 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.021485"], ["state", "pending"], ["target_id", 2487], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.021485"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2487 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.027219"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.027219"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2488 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.030664"], ["state", "pending"], ["target_id", 2488], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.030664"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2488) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:53:56.033859"], ["target_id", 2488], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:53:56.033859"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2488 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2488 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.040366"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.040366"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2489 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.044978"], ["state", "pending"], ["target_id", 2489], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.044978"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2489 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2489 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.052780"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.052780"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2490 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.056226"], ["state", "pending"], ["target_id", 2490], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.056226"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2490) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.059312"], ["group_id", 1], ["target_id", 2490], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.059312"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2490 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2490 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.067171"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.067171"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2491 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.070916"], ["state", "pending"], ["target_id", 2491], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.070916"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2491) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:53:56.073855"], ["target_id", 2491], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.073855"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2491 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2491 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.081766"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.081766"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2492 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.085421"], ["state", "pending"], ["target_id", 2492], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.085421"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2492 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2492 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3127 [["group_id", 1], ["updated_at", "2015-09-28 03:53:56.090547"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2492 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2492 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.097772"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.097772"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2493 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.101320"], ["state", "pending"], ["target_id", 2493], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.101320"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3128]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2493]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2493 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2493 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.110680"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.110680"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2494 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.113986"], ["state", "pending"], ["target_id", 2494], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.113986"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2494) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:53:56.117236"], ["target_id", 2494], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:53:56.117236"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3129]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2494]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2494 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2494 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.125725"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.125725"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2495 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.129250"], ["state", "pending"], ["target_id", 2495], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.129250"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2495) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.132767"], ["group_id", 1], ["target_id", 2495], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.132767"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2495 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3130]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2495]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2495 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.144328"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.144328"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2496 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.148151"], ["state", "pending"], ["target_id", 2496], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.148151"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2496 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2496 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.155243"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.155243"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2497 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.158920"], ["state", "pending"], ["target_id", 2497], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.158920"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2497) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:53:56.162095"], ["target_id", 2497], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:53:56.162095"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2497 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2497 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.168993"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.168993"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2498 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.172808"], ["state", "pending"], ["target_id", 2498], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.172808"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2498) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.176366"], ["group_id", 1], ["target_id", 2498], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.176366"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2498 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2498 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.185131"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.185131"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2499 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.190100"], ["state", "pending"], ["target_id", 2499], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.190100"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2499 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'OKKfVA_kQZ2-k2XfFs8nxwiinhsH-DIt6tJcKbAQU3Tg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.194025"], ["target_id", 2499], ["target_type", "User"], ["token", "OKKfVA_kQZ2-k2XfFs8nxwiinhsH-DIt6tJcKbAQU3Tg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.194025"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.200471"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.200471"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2500 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.204153"], ["state", "pending"], ["target_id", 2500], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.204153"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2500 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 't9URpPYYbohugRRvDeIPkA0BehHK_aNYel74vijw2Lpw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.208474"], ["target_id", 2500], ["target_type", "User"], ["token", "t9URpPYYbohugRRvDeIPkA0BehHK_aNYel74vijw2Lpw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.208474"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2500 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:53:56.215705"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:53:56.215705"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2501 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.219654"], ["state", "pending"], ["target_id", 2501], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.219654"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2501 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'uSEMEUsM4iPSE-dj67aIpwOzKb_-FbUbBpt-E4yU_R8Q' LIMIT 1 SQL (0.5ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.224508"], ["target_id", 2501], ["target_type", "User"], ["token", "uSEMEUsM4iPSE-dj67aIpwOzKb_-FbUbBpt-E4yU_R8Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.224508"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 311 [["active", "f"], ["updated_at", "2015-09-28 03:53:56.229507"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2501 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'BNQhLjEE334xZOVvwy-bkQjCBm2rmvJq1dSomBgnpPRg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:53:56.233065"], ["target_id", 2501], ["target_type", "User"], ["token", "BNQhLjEE334xZOVvwy-bkQjCBm2rmvJq1dSomBgnpPRg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:53:56.233065"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.464030"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.464030"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2502 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.6ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.492358"], ["state", "pending"], ["target_id", 2502], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.492358"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 2502 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.500129"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.500129"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2503 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.503693"], ["state", "pending"], ["target_id", 2503], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.503693"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.507863"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.507863"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2504 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.511275"], ["state", "pending"], ["target_id", 2504], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.511275"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.515545"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.515545"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2505 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.520358"], ["state", "pending"], ["target_id", 2505], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.520358"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2505 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3140 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:58:15.524435"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.535470"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.535470"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2506 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.539836"], ["state", "pending"], ["target_id", 2506], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.539836"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2506 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3141 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:58:15.544194"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.550279"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.550279"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2507 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.556254"], ["state", "pending"], ["target_id", 2507], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.556254"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2507 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3142 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:58:15.559443"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.564948"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.564948"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2508 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.568355"], ["state", "pending"], ["target_id", 2508], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.568355"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2508 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3143 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 03:58:15.571619"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.577399"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.577399"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2509 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.580427"], ["state", "pending"], ["target_id", 2509], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.580427"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2509 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3144]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.587095"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.587095"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.590593"], ["state", "pending"], ["target_id", 2510], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.590593"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3145 [["state", "sent"], ["updated_at", "2015-09-28 03:58:15.595390"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2510 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3145 [["sent_time", "2015-09-28 03:58:15.596571"], ["updated_at", "2015-09-28 03:58:15.597932"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3145]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.604985"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.604985"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.608566"], ["state", "pending"], ["target_id", 2511], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.608566"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2511 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:58:15.612442') NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2511 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:58:15.612442') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2511 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3146]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.623703"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.623703"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.628423"], ["state", "pending"], ["target_id", 2512], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.628423"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2512 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:58:15.633909') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2512 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:58:15.633909') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2512 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3147]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.644316"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.644316"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2513 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.648761"], ["state", "pending"], ["target_id", 2513], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.648761"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2513 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2513 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:58:15.655798') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2513 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:58:15.655798') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2513 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3148]]  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.665521"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.665521"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.669727"], ["state", "pending"], ["target_id", 2514], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.669727"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2514 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 3149)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3149 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:15.676857"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3149]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2514]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2514 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.5ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2514]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3149 [["sent_time", "2015-09-28 03:58:15.687995"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:15.691889"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3149]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2514]]  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2514 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.3ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (4.0ms) NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2514 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'e7nPqO0DmTRq5Z-Tc-GcdAwYrHDJ_icbTRwq6Q05K-2g' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.755725"], ["target_id", 2514], ["target_type", "User"], ["token", "e7nPqO0DmTRq5Z-Tc-GcdAwYrHDJ_icbTRwq6Q05K-2g"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.755725"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 218.8ms Sent mail to user@example.com (8.5ms) Date: Mon, 28 Sep 2015 13:58:15 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608bad7e35dc_12fa93fe9894602005731f@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.937942"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.937942"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2515 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.941428"], ["state", "pending_as_aggregation_parent"], ["target_id", 2515], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.941428"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2515 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.944623"], ["state", "pending"], ["target_id", 2515], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.944623"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2515 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2515 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 3151)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.952638"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.952638"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.955862"], ["state", "pending"], ["target_id", 2516], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.955862"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3152 [["state", "sent"], ["updated_at", "2015-09-28 03:58:15.959727"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3152 [["sent_time", "2015-09-28 03:58:15.961033"], ["updated_at", "2015-09-28 03:58:15.962407"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3152]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2516]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2516 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2516 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'tuvliEgIgGnSUlKbXC_IfgR6z1uhGefXMSk7c2C_O2SQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.971507"], ["target_id", 2516], ["target_type", "User"], ["token", "tuvliEgIgGnSUlKbXC_IfgR6z1uhGefXMSk7c2C_O2SQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.971507"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.3ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 13:58:15 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608bad7ee28e_12fa93fe9894602005749b@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.979399"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.979399"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2517 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.982974"], ["state", "pending"], ["target_id", 2517], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.982974"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2517 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3153 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 03:58:15.987142"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:15.991494"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:15.991494"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2518 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:15.994700"], ["state", "pending"], ["target_id", 2518], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:15.994700"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2518) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:58:16.000286"], ["target_id", 2518], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:58:16.000286"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3154]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2518]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2518 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2518 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.008819"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.008819"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.011995"], ["state", "pending"], ["target_id", 2519], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.011995"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3155]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2519]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2519 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.019822"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.019822"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2520 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.023333"], ["state", "pending"], ["target_id", 2520], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.023333"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2520 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2520 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3156 [["state", "sent"], ["updated_at", "2015-09-28 03:58:16.027721"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2520 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3156 [["sent_time", "2015-09-28 03:58:16.028901"], ["updated_at", "2015-09-28 03:58:16.030323"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3156]] User Load (0.5ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2520]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2520 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2520 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2520 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'PqGY3Xaq_e3Xvd82CH1alABqamhecn3rNDT9mqctqKrQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.039340"], ["target_id", 2520], ["target_type", "User"], ["token", "PqGY3Xaq_e3Xvd82CH1alABqamhecn3rNDT9mqctqKrQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.039340"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.4ms Sent mail to user@example.com (1.6ms) Date: Mon, 28 Sep 2015 13:58:16 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608bad8a6b9_12fa93fe989460200575a5@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.046811"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.046811"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2521 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.050244"], ["state", "pending"], ["target_id", 2521], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.050244"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3157]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2521]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2521 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2521 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.058321"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.058321"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2522 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.061404"], ["state", "pending"], ["target_id", 2522], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.061404"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3158]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2522]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2522 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2522]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2522 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3158 [["sent_time", "2015-09-28 03:58:16.065955"], ["state", "sent"], ["updated_at", "2015-09-28 03:58:16.068479"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2522 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.074860"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.074860"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2523 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.078077"], ["state", "pending"], ["target_id", 2523], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.078077"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2523 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.081911"], ["state", "pending"], ["target_id", 2523], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.081911"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3160]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2523]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2523 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2523]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2523 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3160 [["sent_time", "2015-09-28 03:58:16.087442"], ["state", "sent"], ["updated_at", "2015-09-28 03:58:16.089879"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2523]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2523 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3159 [["sent_time", "2015-09-28 03:58:16.091766"], ["state", "sent"], ["updated_at", "2015-09-28 03:58:16.094330"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2523 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2523 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.102673"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.102673"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2524 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.106082"], ["state", "read"], ["target_id", 2524], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.106082"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3161]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2524]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2524 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.113043"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.113043"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.117292"], ["group_id", 2], ["state", "pending"], ["target_id", 2525], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.117292"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3162]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2525]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2525 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2525]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3162 [["sent_time", "2015-09-28 03:58:16.122317"], ["state", "sent"], ["updated_at", "2015-09-28 03:58:16.125953"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3162]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2525]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2525 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.1ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.5ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2525 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '84nuVHd18YBjDdDZ1QR9PAycRHEn46WITS858KgSDaow' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.139722"], ["target_id", 2525], ["target_type", "User"], ["token", "84nuVHd18YBjDdDZ1QR9PAycRHEn46WITS858KgSDaow"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.139722"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.2ms Sent mail to user@example.com (1.6ms) Date: Mon, 28 Sep 2015 13:58:16 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608bad822ec8_12fa93fe989460200576ad@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.146689"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.146689"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2526 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2526 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.151833"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2526], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.151833"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2526 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2526 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3163 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.155889"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2526 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2526 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3163 [["sent_time", "2015-09-28 03:58:16.157054"], ["updated_at", "2015-09-28 03:58:16.159368"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3163]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.166027"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.166027"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2527 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2527 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.170497"], ["group_id", 1], ["state", "pending"], ["target_id", 2527], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.170497"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2527 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3164) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.175858"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.175858"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2528 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2528 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.180320"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2528], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.180320"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2528 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2528 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.184965"], ["group_id", 1], ["state", "pending"], ["target_id", 2528], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.184965"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2528 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3166) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.190750"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.190750"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2529 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2529 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.195484"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2529], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.195484"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2529 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2529 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.200113"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2529], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.200113"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2529 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2529 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.205155"], ["group_id", 1], ["state", "pending"], ["target_id", 2529], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.205155"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2529 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3169) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.210690"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.210690"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.214886"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 2530], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.214886"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.219057"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 2530], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.219057"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2530 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.223314"], ["group_id", 1], ["state", "pending"], ["target_id", 2530], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.223314"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2530 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3172) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.228942"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.228942"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.233328"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2531], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.233328"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.238004"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2531], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.238004"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2531 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.242640"], ["group_id", 1], ["state", "pending"], ["target_id", 2531], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.242640"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2531 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3175) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.248859"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.248859"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 17:58:16.251022"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.255252"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2532 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:58:16.257245') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2532 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:58:16.257245') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2532 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 03:58:16.262756"], ["group_id", 1], ["parent_id", 3176], ["state", "pending"], ["target_id", 2532], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.262756"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.266940"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.266940"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2533 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2533 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:58:16.268084"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2533], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.271579"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2533 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:58:16.273525')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2533 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2533 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.277567"], ["group_id", 1], ["state", "pending"], ["target_id", 2533], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.277567"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.281790"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.281790"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2534 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2534 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 02:58:16.282845"], ["group_id", 1], ["state", "pending"], ["target_id", 2534], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.286000"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2534 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:58:16.288516')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2534 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2534 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.292556"], ["group_id", 1], ["state", "pending"], ["target_id", 2534], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.292556"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.296553"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.296553"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2535 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2535 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.301701"], ["group_id", 1], ["state", "pending"], ["target_id", 2535], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.301701"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2535 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3182) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2535 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3182) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.308715"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.308715"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.312966"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2536], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.312966"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3183 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.317252"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3183 [["sent_time", "2015-09-28 03:58:16.318554"], ["updated_at", "2015-09-28 03:58:16.320987"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2536 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.325184"], ["group_id", 1], ["state", "pending"], ["target_id", 2536], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.325184"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2536 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3184) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2536 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3184) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.332350"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.332350"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.336852"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2537], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.336852"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3185 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.341098"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3185 [["sent_time", "2015-09-28 03:58:16.342583"], ["updated_at", "2015-09-28 03:58:16.345158"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.349387"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2537], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.349387"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3186 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.354341"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3186 [["sent_time", "2015-09-28 03:58:16.355585"], ["updated_at", "2015-09-28 03:58:16.358084"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2537 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.362176"], ["group_id", 1], ["state", "pending"], ["target_id", 2537], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.362176"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2537 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3187) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2537 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3187) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.369459"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.369459"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.373809"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.373809"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3188 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.377853"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3188 [["sent_time", "2015-09-28 03:58:16.379055"], ["updated_at", "2015-09-28 03:58:16.381427"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.385943"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.385943"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3189 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.389769"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3189 [["sent_time", "2015-09-28 03:58:16.390882"], ["updated_at", "2015-09-28 03:58:16.393365"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.397913"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.397913"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3190 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.401760"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3190 [["sent_time", "2015-09-28 03:58:16.403174"], ["updated_at", "2015-09-28 03:58:16.405709"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.409969"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.409969"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3191 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.414026"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3191 [["sent_time", "2015-09-28 03:58:16.415152"], ["updated_at", "2015-09-28 03:58:16.418195"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.423089"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.423089"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3192 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.427359"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3192 [["sent_time", "2015-09-28 03:58:16.428545"], ["updated_at", "2015-09-28 03:58:16.430868"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.435298"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.435298"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3193 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.439491"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3193 [["sent_time", "2015-09-28 03:58:16.440697"], ["updated_at", "2015-09-28 03:58:16.443129"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.447513"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.447513"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3194 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.451489"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3194 [["sent_time", "2015-09-28 03:58:16.452650"], ["updated_at", "2015-09-28 03:58:16.454947"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.459490"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.459490"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3195 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.463504"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3195 [["sent_time", "2015-09-28 03:58:16.464677"], ["updated_at", "2015-09-28 03:58:16.467390"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.471985"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.471985"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3196 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.476049"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3196 [["sent_time", "2015-09-28 03:58:16.477157"], ["updated_at", "2015-09-28 03:58:16.479469"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.484060"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.484060"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3197 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.487897"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3197 [["sent_time", "2015-09-28 03:58:16.488987"], ["updated_at", "2015-09-28 03:58:16.491435"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.495737"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.495737"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3198 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.499644"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3198 [["sent_time", "2015-09-28 03:58:16.500761"], ["updated_at", "2015-09-28 03:58:16.503310"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2538 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.507830"], ["group_id", 1], ["state", "pending"], ["target_id", 2538], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.507830"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2538 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3199) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2538 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3199) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.515752"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.515752"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2539 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2539 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.519835"], ["group_id", 1], ["state", "pending"], ["target_id", 2539], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.519835"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2539 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2539 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2539 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3200)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2539 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2539 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3200 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.529996"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.534394"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.534394"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2540 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2540 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.538686"], ["group_id", 1], ["state", "pending"], ["target_id", 2540], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.538686"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2540 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2540 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2540 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3201)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2540 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2540 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3201 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.553254"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.558471"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.558471"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2541 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2541 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.563407"], ["group_id", 1], ["state", "pending"], ["target_id", 2541], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.563407"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2541 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2541 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2541 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3202)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2541 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2541 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3202 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.572241"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3202]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.579852"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.579852"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2542 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2542 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.584444"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2542], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.584444"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2542 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2542 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:00:16.584444"], ["group_id", 1], ["state", "pending"], ["target_id", 2542], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.589469"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2542 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2542 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2542 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3204)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2542 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2542 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3204 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 03:58:16.599194"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.605528"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.605528"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2543 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2543 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.610592"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2543], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.610592"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2543 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:58:16.612929') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2543 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 03:58:16.612929') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2543 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2543 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 04:00:16.610592"], ["group_id", 1], ["parent_id", 3205], ["state", "pending"], ["target_id", 2543], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.619012"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3206]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.624830"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.624830"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2544 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2544 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.629376"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2544], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.629376"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2544 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2544 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.633520"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2544], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.633520"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2544 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2544 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.637681"], ["group_id", 1], ["state", "pending"], ["target_id", 2544], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.637681"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2544 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2544 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2544 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3209)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.646346"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.646346"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2545 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2545 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.651856"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2545], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.651856"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2545 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2545 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.656551"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2545], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.656551"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2545 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2545 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 03:58:16.661206"], ["group_id", 1], ["state", "pending"], ["target_id", 2545], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.661206"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2545 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2545 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2545 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3212) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3212]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.670640"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.670640"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2546 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.676103"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.676103"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2547 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2547 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.682919"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.682919"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2548 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.689449"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.689449"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2549 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.693425"], ["state", "pending"], ["target_id", 2549], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.693425"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2549) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:58:16.696780"], ["target_id", 2549], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.696780"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2549 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.703347"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.703347"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2550 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.712460"], ["state", "pending"], ["target_id", 2550], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.712460"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2550 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.718265"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.718265"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2551 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.721605"], ["state", "pending"], ["target_id", 2551], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.721605"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2551) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:58:16.724468"], ["target_id", 2551], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:58:16.724468"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2551 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2551 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.730807"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.730807"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2552 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.734321"], ["state", "pending"], ["target_id", 2552], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.734321"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2552 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2552 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.741305"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.741305"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2553 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.745095"], ["state", "pending"], ["target_id", 2553], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.745095"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2553) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.748586"], ["group_id", 1], ["target_id", 2553], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.748586"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2553 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2553 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.757212"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.757212"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2554 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.760493"], ["state", "pending"], ["target_id", 2554], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.760493"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2554) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:58:16.763635"], ["target_id", 2554], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.763635"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2554 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2554 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.771001"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.771001"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2555 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.774344"], ["state", "pending"], ["target_id", 2555], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.774344"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2555 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2555 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3219 [["group_id", 1], ["updated_at", "2015-09-28 03:58:16.779043"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2555 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2555 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.786401"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.786401"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2556 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.790042"], ["state", "pending"], ["target_id", 2556], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.790042"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3220]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2556]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2556 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2556 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.798914"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.798914"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2557 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.803171"], ["state", "pending"], ["target_id", 2557], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.803171"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2557) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:58:16.806329"], ["target_id", 2557], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:58:16.806329"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3221]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2557]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2557 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2557 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.815825"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.815825"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2558 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.819373"], ["state", "pending"], ["target_id", 2558], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.819373"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2558) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.822468"], ["group_id", 1], ["target_id", 2558], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.822468"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2558 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3222]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2558]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2558 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.832083"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.832083"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2559 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.836082"], ["state", "pending"], ["target_id", 2559], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.836082"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2559 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2559 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.843632"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.843632"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2560 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.847311"], ["state", "pending"], ["target_id", 2560], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.847311"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2560) LIMIT 1 SQL (0.5ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 03:58:16.850543"], ["target_id", 2560], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 03:58:16.850543"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2560 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2560 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.858220"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.858220"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2561 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.861826"], ["state", "pending"], ["target_id", 2561], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.861826"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2561) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.865019"], ["group_id", 1], ["target_id", 2561], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.865019"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2561 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2561 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.873660"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.873660"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2562 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.877175"], ["state", "pending"], ["target_id", 2562], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.877175"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2562 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'pdzRlW8UDt_6sIGWyoCivwFBdgxvf7K92f9h3-cv9rQw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.881143"], ["target_id", 2562], ["target_type", "User"], ["token", "pdzRlW8UDt_6sIGWyoCivwFBdgxvf7K92f9h3-cv9rQw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.881143"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.887185"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.887185"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2563 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.891114"], ["state", "pending"], ["target_id", 2563], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.891114"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2563 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '-NYpVYT4wMOhnanrEnrF2wwsLDdhCbk5_jr3YBt5si7g' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.894904"], ["target_id", 2563], ["target_type", "User"], ["token", "-NYpVYT4wMOhnanrEnrF2wwsLDdhCbk5_jr3YBt5si7g"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.894904"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2563 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 03:58:16.902688"], ["email", "user@example.com"], ["updated_at", "2015-09-28 03:58:16.902688"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2564 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.906717"], ["state", "pending"], ["target_id", 2564], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.906717"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2564 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '9SalgE6CaktMa5L98BwOdw4fzQDiTG30LakDT5KTSaqA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.910621"], ["target_id", 2564], ["target_type", "User"], ["token", "9SalgE6CaktMa5L98BwOdw4fzQDiTG30LakDT5KTSaqA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.910621"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 319 [["active", "f"], ["updated_at", "2015-09-28 03:58:16.913537"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2564 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'APAtN0nINezqfLRQ94WuGgQ7QkZkbWhGNdkCcS76kUKw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 03:58:16.917035"], ["target_id", 2564], ["target_type", "User"], ["token", "APAtN0nINezqfLRQ94WuGgQ7QkZkbWhGNdkCcS76kUKw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 03:58:16.917035"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.418598"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.418598"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2565 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (6.8ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.454748"], ["state", "pending"], ["target_id", 2565], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.454748"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 2565 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.469277"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.469277"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2566 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.472523"], ["state", "pending"], ["target_id", 2566], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.472523"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.476399"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.476399"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2567 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.479689"], ["state", "pending"], ["target_id", 2567], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.479689"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.483835"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.483835"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2568 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.487330"], ["state", "pending"], ["target_id", 2568], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.487330"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2568 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3232 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:20:32.490544"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.499640"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.499640"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2569 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.503205"], ["state", "pending"], ["target_id", 2569], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.503205"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2569 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3233 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:20:32.506355"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.511567"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.511567"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2570 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.516880"], ["state", "pending"], ["target_id", 2570], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.516880"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2570 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3234 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:20:32.519961"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.525080"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.525080"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2571 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.528358"], ["state", "pending"], ["target_id", 2571], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.528358"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2571 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3235 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:20:32.531191"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.536342"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.536342"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2572 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.539434"], ["state", "pending"], ["target_id", 2572], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.539434"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2572 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3236]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.547055"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.547055"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2573 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.550677"], ["state", "pending"], ["target_id", 2573], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.550677"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2573 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2573 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3237 [["state", "sent"], ["updated_at", "2015-09-28 04:20:32.556066"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2573 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3237 [["sent_time", "2015-09-28 04:20:32.557300"], ["updated_at", "2015-09-28 04:20:32.558740"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3237]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.564960"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.564960"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2574 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.569071"], ["state", "pending"], ["target_id", 2574], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.569071"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2574 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:20:32.573096') NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2574 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:20:32.573096') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2574 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3238]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.582320"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.582320"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2575 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.585910"], ["state", "pending"], ["target_id", 2575], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.585910"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2575 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2575 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:20:32.590303') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2575 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:20:32.590303') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2575 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3239]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.599533"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.599533"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2576 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.603298"], ["state", "pending"], ["target_id", 2576], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.603298"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2576 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2576 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:20:32.607717') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2576 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:20:32.607717') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2576 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3240]]  (0.4ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.617416"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.617416"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2577 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.621326"], ["state", "pending"], ["target_id", 2577], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.621326"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2577 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2577 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 3241)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2577 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3241 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:32.628364"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3241]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2577]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2577 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2577]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2577 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3241 [["sent_time", "2015-09-28 04:20:32.638516"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:32.641155"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2577 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3241]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2577]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2577 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2577 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.4ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (4.1ms) NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2577 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'WMHiJ-YP_mQo_lEvg_z9YQZOM-sWwyyzPQKnQgOz_4Yg' LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.692935"], ["target_id", 2577], ["target_type", "User"], ["token", "WMHiJ-YP_mQo_lEvg_z9YQZOM-sWwyyzPQKnQgOz_4Yg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.692935"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 207.9ms Sent mail to user@example.com (8.3ms) Date: Mon, 28 Sep 2015 14:20:32 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c010d3530_135203ffbc584020094642@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.872120"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.872120"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2578 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.875975"], ["state", "pending_as_aggregation_parent"], ["target_id", 2578], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.875975"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2578 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.879170"], ["state", "pending"], ["target_id", 2578], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.879170"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2578 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2578 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 3243)  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.886671"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.886671"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2579 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.890449"], ["state", "pending"], ["target_id", 2579], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.890449"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2579 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2579 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3244 [["state", "sent"], ["updated_at", "2015-09-28 04:20:32.894784"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2579 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3244 [["sent_time", "2015-09-28 04:20:32.896028"], ["updated_at", "2015-09-28 04:20:32.897358"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3244]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2579]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2579 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2579 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.3ms) NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2579 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'lbLK_-st7l9pxbRSUT5jnwVs3iah_9xb2HI83_xe58Kg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.907414"], ["target_id", 2579], ["target_type", "User"], ["token", "lbLK_-st7l9pxbRSUT5jnwVs3iah_9xb2HI83_xe58Kg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.907414"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.1ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 14:20:32 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c010de6c6_135203ffbc58402009479f@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.916387"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.916387"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2580 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.920210"], ["state", "pending"], ["target_id", 2580], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.920210"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2580 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3245 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 04:20:32.923314"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.927348"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.927348"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2581 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.930592"], ["state", "pending"], ["target_id", 2581], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.930592"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2581) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:20:32.935725"], ["target_id", 2581], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:20:32.935725"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3246]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2581]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2581 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2581 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.944756"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.944756"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2582 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.948082"], ["state", "pending"], ["target_id", 2582], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.948082"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3247]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2582]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2582 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2582 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.956943"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.956943"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2583 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.960184"], ["state", "pending"], ["target_id", 2583], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.960184"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2583 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2583 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3248 [["state", "sent"], ["updated_at", "2015-09-28 04:20:32.966239"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2583 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3248 [["sent_time", "2015-09-28 04:20:32.967547"], ["updated_at", "2015-09-28 04:20:32.969054"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3248]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2583]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2583 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2583 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.3ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2583 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'F_VJIUZ5FBFTyxR26JjYUwFHI0_qRKQuy6fuEBaSLnVA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.977338"], ["target_id", 2583], ["target_type", "User"], ["token", "F_VJIUZ5FBFTyxR26JjYUwFHI0_qRKQuy6fuEBaSLnVA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.977338"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.2ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 14:20:32 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c010efa85_135203ffbc58402009487e@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.986164"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.986164"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2584 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:32.989591"], ["state", "pending"], ["target_id", 2584], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:32.989591"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3249]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2584]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2584 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2584 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:32.997552"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:32.997552"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2585 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.000980"], ["state", "pending"], ["target_id", 2585], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.000980"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3250]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2585]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2585 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2585]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2585 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3250 [["sent_time", "2015-09-28 04:20:33.005407"], ["state", "sent"], ["updated_at", "2015-09-28 04:20:33.008046"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2585 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.015135"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.015135"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2586 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.018380"], ["state", "pending"], ["target_id", 2586], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.018380"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2586 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.021863"], ["state", "pending"], ["target_id", 2586], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.021863"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3252]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2586]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2586 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2586]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2586 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3252 [["sent_time", "2015-09-28 04:20:33.026490"], ["state", "sent"], ["updated_at", "2015-09-28 04:20:33.029083"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2586]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2586 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3251 [["sent_time", "2015-09-28 04:20:33.031106"], ["state", "sent"], ["updated_at", "2015-09-28 04:20:33.033612"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2586 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2586 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.041824"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.041824"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2587 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.045150"], ["state", "read"], ["target_id", 2587], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.045150"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3253]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2587]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2587 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.053182"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.053182"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2588 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2588 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.057525"], ["group_id", 2], ["state", "pending"], ["target_id", 2588], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.057525"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3254]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2588]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2588 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2588]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2588 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2588 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3254 [["sent_time", "2015-09-28 04:20:33.062656"], ["state", "sent"], ["updated_at", "2015-09-28 04:20:33.067073"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2588 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2588 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3254]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2588]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2588 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2588 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2588 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2588 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'q1ZqTxa50LH65aCa1RIWOg0KjPrw2zEoDCyvOJqwqgoA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.079937"], ["target_id", 2588], ["target_type", "User"], ["token", "q1ZqTxa50LH65aCa1RIWOg0KjPrw2zEoDCyvOJqwqgoA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.079937"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.3ms Sent mail to user@example.com (1.6ms) Date: Mon, 28 Sep 2015 14:20:33 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c011144be_135203ffbc5840200949d7@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.086990"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.086990"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2589 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2589 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.091633"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2589], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.091633"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2589 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2589 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3255 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.095916"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2589 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2589 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3255 [["sent_time", "2015-09-28 04:20:33.097171"], ["updated_at", "2015-09-28 04:20:33.099996"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3255]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.106753"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.106753"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2590 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2590 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.111041"], ["group_id", 1], ["state", "pending"], ["target_id", 2590], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.111041"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2590 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3256) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.117602"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.117602"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2591 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2591 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.122516"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2591], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.122516"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2591 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2591 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.127142"], ["group_id", 1], ["state", "pending"], ["target_id", 2591], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.127142"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2591 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3258) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.133090"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.133090"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2592 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2592 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.137456"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2592], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.137456"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2592 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2592 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.141802"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2592], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.141802"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2592 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2592 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.145810"], ["group_id", 1], ["state", "pending"], ["target_id", 2592], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.145810"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2592 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3261) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.151382"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.151382"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2593 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2593 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.156004"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 2593], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.156004"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2593 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2593 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.160510"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 2593], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.160510"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2593 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2593 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.165985"], ["group_id", 1], ["state", "pending"], ["target_id", 2593], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.165985"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2593 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3264) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.171448"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.171448"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2594 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2594 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.175817"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2594], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.175817"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2594 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2594 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.179915"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2594], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.179915"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2594 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2594 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.184061"], ["group_id", 1], ["state", "pending"], ["target_id", 2594], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.184061"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2594 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3267) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.190224"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.190224"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2595 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2595 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 18:20:33.191449"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2595], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.195100"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2595 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:20:33.197348') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2595 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:20:33.197348') ORDER BY created_at DESC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2595 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2595 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 04:20:33.203243"], ["group_id", 1], ["parent_id", 3268], ["state", "pending"], ["target_id", 2595], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.203243"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.207356"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.207356"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2596 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2596 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 03:20:33.208543"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2596], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.211852"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2596 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:20:33.214726')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2596 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2596 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.219178"], ["group_id", 1], ["state", "pending"], ["target_id", 2596], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.219178"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.223237"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.223237"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2597 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2597 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 03:20:33.224385"], ["group_id", 1], ["state", "pending"], ["target_id", 2597], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.227784"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2597 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:20:33.229912')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2597 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2597 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.233829"], ["group_id", 1], ["state", "pending"], ["target_id", 2597], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.233829"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.238288"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.238288"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2598 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2598 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.242859"], ["group_id", 1], ["state", "pending"], ["target_id", 2598], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.242859"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2598 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3274) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2598 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3274) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.250230"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.250230"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.254659"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2599], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.254659"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3275 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.258960"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3275 [["sent_time", "2015-09-28 04:20:33.260199"], ["updated_at", "2015-09-28 04:20:33.262577"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2599 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.268016"], ["group_id", 1], ["state", "pending"], ["target_id", 2599], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.268016"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2599 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3276) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2599 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3276) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.275230"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.275230"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.279752"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2600], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.279752"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3277 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.284080"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3277 [["sent_time", "2015-09-28 04:20:33.285385"], ["updated_at", "2015-09-28 04:20:33.287929"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.292406"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2600], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.292406"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3278 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.296444"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3278 [["sent_time", "2015-09-28 04:20:33.297742"], ["updated_at", "2015-09-28 04:20:33.300558"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2600 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.305073"], ["group_id", 1], ["state", "pending"], ["target_id", 2600], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.305073"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2600 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3279) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2600 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3279) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.312307"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.312307"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.317975"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2601], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.317975"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3280 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.322281"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3280 [["sent_time", "2015-09-28 04:20:33.323463"], ["updated_at", "2015-09-28 04:20:33.325776"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.330303"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2601], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.330303"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3281 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.334739"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3281 [["sent_time", "2015-09-28 04:20:33.335818"], ["updated_at", "2015-09-28 04:20:33.338206"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.342488"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2601], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.342488"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3282 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.347321"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3282 [["sent_time", "2015-09-28 04:20:33.348531"], ["updated_at", "2015-09-28 04:20:33.351457"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.355955"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2601], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.355955"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3283 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.359947"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3283 [["sent_time", "2015-09-28 04:20:33.361168"], ["updated_at", "2015-09-28 04:20:33.364374"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.369080"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2601], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.369080"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3284 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.373046"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3284 [["sent_time", "2015-09-28 04:20:33.374164"], ["updated_at", "2015-09-28 04:20:33.376547"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.381004"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2601], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.381004"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3285 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.384929"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3285 [["sent_time", "2015-09-28 04:20:33.386100"], ["updated_at", "2015-09-28 04:20:33.388713"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.393574"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2601], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.393574"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3286 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.397685"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3286 [["sent_time", "2015-09-28 04:20:33.398798"], ["updated_at", "2015-09-28 04:20:33.401140"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.405582"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2601], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.405582"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3287 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.409596"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3287 [["sent_time", "2015-09-28 04:20:33.410838"], ["updated_at", "2015-09-28 04:20:33.413415"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.418184"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2601], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.418184"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3288 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.421922"]]  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3288 [["sent_time", "2015-09-28 04:20:33.423220"], ["updated_at", "2015-09-28 04:20:33.426651"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.431144"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2601], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.431144"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3289 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.435105"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3289 [["sent_time", "2015-09-28 04:20:33.436282"], ["updated_at", "2015-09-28 04:20:33.438806"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.443858"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2601], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.443858"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3290 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.448063"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3290 [["sent_time", "2015-09-28 04:20:33.449174"], ["updated_at", "2015-09-28 04:20:33.451550"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2601 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.455784"], ["group_id", 1], ["state", "pending"], ["target_id", 2601], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.455784"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2601 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3291) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2601 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3291) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.463262"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.463262"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.469008"], ["group_id", 1], ["state", "pending"], ["target_id", 2602], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.469008"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2602 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3292)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2602 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3292 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.482038"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.486903"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.486903"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2603 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2603 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.491246"], ["group_id", 1], ["state", "pending"], ["target_id", 2603], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.491246"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2603 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2603 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2603 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3293)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2603 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2603 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3293 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.505182"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.510452"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.510452"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2604 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2604 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.516621"], ["group_id", 1], ["state", "pending"], ["target_id", 2604], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.516621"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2604 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2604 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2604 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3294)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2604 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2604 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3294 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.525600"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3294]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.532106"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.532106"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.536853"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2605], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.536853"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:33.536853"], ["group_id", 1], ["state", "pending"], ["target_id", 2605], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.541982"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2605 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3296)  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2605 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3296 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:20:33.551319"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.556509"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.556509"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2606 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2606 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.561399"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2606], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.561399"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2606 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:20:33.563673') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2606 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:20:33.563673') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2606 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2606 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 04:22:33.561399"], ["group_id", 1], ["parent_id", 3297], ["state", "pending"], ["target_id", 2606], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.570703"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3298]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.576649"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.576649"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.580759"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2607], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.580759"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.584798"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2607], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.584798"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.588965"], ["group_id", 1], ["state", "pending"], ["target_id", 2607], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.588965"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2607 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2607 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3301)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.598039"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.598039"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2608 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2608 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.602692"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2608], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.602692"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2608 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2608 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.607194"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2608], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.607194"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2608 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2608 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:20:33.611346"], ["group_id", 1], ["state", "pending"], ["target_id", 2608], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.611346"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2608 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2608 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2608 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3304) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3304]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.621688"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.621688"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2609 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.627704"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.627704"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2610 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2610 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.635012"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.635012"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2611 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.640848"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.640848"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.644580"], ["state", "pending"], ["target_id", 2612], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.644580"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2612) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:20:33.647872"], ["target_id", 2612], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.647872"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2612 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.653105"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.653105"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.656718"], ["state", "pending"], ["target_id", 2613], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.656718"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2613 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.662089"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.662089"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.666442"], ["state", "pending"], ["target_id", 2614], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.666442"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2614) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:20:33.669835"], ["target_id", 2614], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:20:33.669835"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2614 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.676241"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.676241"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2615 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.679530"], ["state", "pending"], ["target_id", 2615], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.679530"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2615 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2615 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.686063"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.686063"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2616 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.689390"], ["state", "pending"], ["target_id", 2616], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.689390"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2616) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.692395"], ["group_id", 1], ["target_id", 2616], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.692395"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2616 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2616 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.700267"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.700267"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2617 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.703856"], ["state", "pending"], ["target_id", 2617], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.703856"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2617) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:20:33.706909"], ["target_id", 2617], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.706909"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2617 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2617 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.714292"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.714292"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.718651"], ["state", "pending"], ["target_id", 2618], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.718651"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3311 [["group_id", 1], ["updated_at", "2015-09-28 04:20:33.723161"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2618 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.730816"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.730816"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2619 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.734442"], ["state", "pending"], ["target_id", 2619], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.734442"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3312]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2619]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2619 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2619 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.744046"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.744046"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.748520"], ["state", "pending"], ["target_id", 2620], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.748520"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2620) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:20:33.752876"], ["target_id", 2620], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:20:33.752876"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3313]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2620]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2620 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.761860"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.761860"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2621 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.766776"], ["state", "pending"], ["target_id", 2621], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.766776"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2621) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.770060"], ["group_id", 1], ["target_id", 2621], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.770060"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2621 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3314]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2621]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2621 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.780399"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.780399"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2622 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.783951"], ["state", "pending"], ["target_id", 2622], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.783951"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2622 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2622 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.791170"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.791170"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2623 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.795126"], ["state", "pending"], ["target_id", 2623], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.795126"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2623) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:20:33.798331"], ["target_id", 2623], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:20:33.798331"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2623 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2623 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.805546"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.805546"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2624 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.808947"], ["state", "pending"], ["target_id", 2624], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.808947"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2624) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.812029"], ["group_id", 1], ["target_id", 2624], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.812029"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2624 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2624 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.821025"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.821025"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2625 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.825492"], ["state", "pending"], ["target_id", 2625], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.825492"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2625 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'ked64mxFDp3CXXr3706LEAt8Sf2CrcRp610xNjsKIjng' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.829356"], ["target_id", 2625], ["target_type", "User"], ["token", "ked64mxFDp3CXXr3706LEAt8Sf2CrcRp610xNjsKIjng"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.829356"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.836464"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.836464"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2626 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.840196"], ["state", "pending"], ["target_id", 2626], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.840196"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2626 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'n_Jjd1xFaIvzY5R_uq4f5AewbEb-xRV6B0mGhYET8avQ' LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.844014"], ["target_id", 2626], ["target_type", "User"], ["token", "n_Jjd1xFaIvzY5R_uq4f5AewbEb-xRV6B0mGhYET8avQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.844014"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2626 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:20:33.850930"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:20:33.850930"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2627 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.854660"], ["state", "pending"], ["target_id", 2627], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.854660"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2627 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'mZc6Mqha4HgauuahG-hvKQ4Lg_zRUC3Hv0Pqad2Fr1Ew' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.858346"], ["target_id", 2627], ["target_type", "User"], ["token", "mZc6Mqha4HgauuahG-hvKQ4Lg_zRUC3Hv0Pqad2Fr1Ew"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.858346"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 327 [["active", "f"], ["updated_at", "2015-09-28 04:20:33.861068"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2627 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.4ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'A6-Tc7UPaF4Ium7mavvnCA-YLiEpjQwJIY4T8dIN9jOg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:20:33.865709"], ["target_id", 2627], ["target_type", "User"], ["token", "A6-Tc7UPaF4Ium7mavvnCA-YLiEpjQwJIY4T8dIN9jOg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:20:33.865709"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.3ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:55.593488"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:55.593488"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2628 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:55.627201"], ["state", "pending"], ["target_id", 2628], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:55.627201"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (1.9ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 2628 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.6ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:55.638031"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:55.638031"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2629 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:55.641335"], ["state", "pending"], ["target_id", 2629], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:55.641335"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:55.645198"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:55.645198"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2630 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:55.648540"], ["state", "pending"], ["target_id", 2630], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:55.648540"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:55.652533"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:55.652533"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2631 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:55.655813"], ["state", "pending"], ["target_id", 2631], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:55.655813"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2631 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3324 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:22:55.659113"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:55.668646"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:55.668646"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2632 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:55.672176"], ["state", "pending"], ["target_id", 2632], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:55.672176"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2632 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3325 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:22:55.675208"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:55.680982"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:55.680982"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2633 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:55.684370"], ["state", "pending"], ["target_id", 2633], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:55.684370"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2633 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3326 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:22:55.687196"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:55.692666"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:55.692666"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2634 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:55.696322"], ["state", "pending"], ["target_id", 2634], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:55.696322"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.9ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2634 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3327 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:22:55.702122"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:55.708289"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:55.708289"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2635 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:55.711505"], ["state", "pending"], ["target_id", 2635], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:55.711505"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2635 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3328]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:55.718898"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:55.718898"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2636 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:55.722209"], ["state", "pending"], ["target_id", 2636], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:55.722209"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2636 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2636 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3329 [["state", "sent"], ["updated_at", "2015-09-28 04:22:55.727335"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2636 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3329 [["sent_time", "2015-09-28 04:22:55.728469"], ["updated_at", "2015-09-28 04:22:55.729937"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3329]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:55.736575"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:55.736575"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2637 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:55.739947"], ["state", "pending"], ["target_id", 2637], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:55.739947"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2637 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:22:55.744020') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2637 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:22:55.744020') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2637 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3330]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:55.753381"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:55.753381"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2638 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:55.757030"], ["state", "pending"], ["target_id", 2638], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:55.757030"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2638 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2638 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:22:55.761838') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2638 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:22:55.761838') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2638 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3331]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:55.769867"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:55.769867"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2639 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:55.773092"], ["state", "pending"], ["target_id", 2639], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:55.773092"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2639 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2639 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:22:55.777235') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2639 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:22:55.777235') ORDER BY created_at DESC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2639 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3332]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:55.785265"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:55.785265"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2640 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:55.788821"], ["state", "pending"], ["target_id", 2640], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:55.788821"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2640 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2640 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 3333)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2640 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3333 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:55.796680"]]  (0.4ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3333]] User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2640]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2640 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2640]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2640 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3333 [["sent_time", "2015-09-28 04:22:55.810454"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:55.813211"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2640 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3333]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2640]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2640 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2640 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.3ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (3.8ms) NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2640 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'Pt023Fn2nmMmvX_uYCrIxA1JTqGYiy9bxARggmdTYLAA' LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:55.875288"], ["target_id", 2640], ["target_type", "User"], ["token", "Pt023Fn2nmMmvX_uYCrIxA1JTqGYiy9bxARggmdTYLAA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:55.875288"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 229.7ms Sent mail to user@example.com (8.1ms) Date: Mon, 28 Sep 2015 14:22:56 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c0a0ed39_137923ff309860204616f1@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.066984"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.066984"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2641 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.070494"], ["state", "pending_as_aggregation_parent"], ["target_id", 2641], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.070494"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2641 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.073570"], ["state", "pending"], ["target_id", 2641], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.073570"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2641 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2641 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 3335)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.080876"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.080876"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2642 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.084230"], ["state", "pending"], ["target_id", 2642], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.084230"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2642 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2642 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3336 [["state", "sent"], ["updated_at", "2015-09-28 04:22:56.088188"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2642 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3336 [["sent_time", "2015-09-28 04:22:56.089394"], ["updated_at", "2015-09-28 04:22:56.090837"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3336]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2642]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2642 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2642 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2642 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'hEN8erCfRJEsnEFMA0vU1gy4xdzUkHd9MsGhtQcBHI5w' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.100739"], ["target_id", 2642], ["target_type", "User"], ["token", "hEN8erCfRJEsnEFMA0vU1gy4xdzUkHd9MsGhtQcBHI5w"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.100739"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 7.0ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 14:22:56 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c0a0198d9_137923ff309860204617e6@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.108645"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.108645"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2643 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.111873"], ["state", "pending"], ["target_id", 2643], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.111873"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2643 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3337 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 04:22:56.115061"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.119225"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.119225"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2644 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.122648"], ["state", "pending"], ["target_id", 2644], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.122648"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2644) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:22:56.128082"], ["target_id", 2644], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:22:56.128082"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3338]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2644]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2644 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2644 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.136726"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.136726"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2645 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.139814"], ["state", "pending"], ["target_id", 2645], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.139814"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3339]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2645]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2645 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2645 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.148458"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.148458"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2646 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.152059"], ["state", "pending"], ["target_id", 2646], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.152059"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2646 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2646 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3340 [["state", "sent"], ["updated_at", "2015-09-28 04:22:56.157813"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2646 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3340 [["sent_time", "2015-09-28 04:22:56.159111"], ["updated_at", "2015-09-28 04:22:56.160522"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3340]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2646]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2646 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2646 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2646 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'EGKezCr0piX0RPOSTi030ws5TMlAIHPFwVqRfJRDGWuw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.168717"], ["target_id", 2646], ["target_type", "User"], ["token", "EGKezCr0piX0RPOSTi030ws5TMlAIHPFwVqRfJRDGWuw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.168717"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.5ms Sent mail to user@example.com (1.6ms) Date: Mon, 28 Sep 2015 14:22:56 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c0a02a067_137923ff309860204618a2@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.176090"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.176090"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2647 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.179304"], ["state", "pending"], ["target_id", 2647], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.179304"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3341]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2647]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2647 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2647 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.187941"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.187941"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2648 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.191165"], ["state", "pending"], ["target_id", 2648], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.191165"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3342]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2648]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2648 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2648]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2648 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3342 [["sent_time", "2015-09-28 04:22:56.195436"], ["state", "sent"], ["updated_at", "2015-09-28 04:22:56.197804"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2648 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.204118"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.204118"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2649 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.207210"], ["state", "pending"], ["target_id", 2649], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.207210"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2649 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.210572"], ["state", "pending"], ["target_id", 2649], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.210572"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3344]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2649]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2649 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2649]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2649 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3344 [["sent_time", "2015-09-28 04:22:56.214820"], ["state", "sent"], ["updated_at", "2015-09-28 04:22:56.217305"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2649]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2649 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3343 [["sent_time", "2015-09-28 04:22:56.219066"], ["state", "sent"], ["updated_at", "2015-09-28 04:22:56.221931"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2649 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2649 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.230038"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.230038"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2650 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.233178"], ["state", "read"], ["target_id", 2650], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.233178"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3345]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2650]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2650 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.240063"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.240063"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2651 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2651 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.244672"], ["group_id", 2], ["state", "pending"], ["target_id", 2651], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.244672"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3346]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2651]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2651 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2651]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2651 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2651 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3346 [["sent_time", "2015-09-28 04:22:56.250256"], ["state", "sent"], ["updated_at", "2015-09-28 04:22:56.254430"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2651 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2651 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3346]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2651]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2651 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2651 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2651 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2651 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '3AbXoUGSXp4-_dmsfEuiHgbGtdQcNdonb9N1JeQS5EkQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.266740"], ["target_id", 2651], ["target_type", "User"], ["token", "3AbXoUGSXp4-_dmsfEuiHgbGtdQcNdonb9N1JeQS5EkQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.266740"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.4ms Sent mail to user@example.com (1.6ms) Date: Mon, 28 Sep 2015 14:22:56 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c0a041edb_137923ff3098602046192b@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.274039"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.274039"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2652 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2652 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.278500"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2652], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.278500"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2652 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2652 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3347 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.283914"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2652 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2652 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3347 [["sent_time", "2015-09-28 04:22:56.285080"], ["updated_at", "2015-09-28 04:22:56.287562"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3347]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.294678"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.294678"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2653 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2653 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.299370"], ["group_id", 1], ["state", "pending"], ["target_id", 2653], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.299370"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2653 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3348) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.305934"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.305934"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2654 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2654 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.311049"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2654], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.311049"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2654 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2654 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.315363"], ["group_id", 1], ["state", "pending"], ["target_id", 2654], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.315363"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2654 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3350) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.321178"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.321178"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2655 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2655 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.325859"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2655], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.325859"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2655 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2655 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.329888"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2655], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.329888"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2655 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2655 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.334053"], ["group_id", 1], ["state", "pending"], ["target_id", 2655], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.334053"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2655 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3353) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.339361"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.339361"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2656 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2656 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.343566"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 2656], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.343566"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2656 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2656 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.347675"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 2656], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.347675"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2656 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2656 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.352080"], ["group_id", 1], ["state", "pending"], ["target_id", 2656], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.352080"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2656 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3356) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.358505"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.358505"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2657 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2657 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.363248"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2657], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.363248"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2657 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2657 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.371715"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2657], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.371715"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2657 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2657 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.376127"], ["group_id", 1], ["state", "pending"], ["target_id", 2657], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.376127"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2657 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3359) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.381908"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.381908"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2658 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2658 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 18:22:56.383019"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2658], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.386460"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2658 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:22:56.388572') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2658 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:22:56.388572') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2658 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2658 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 04:22:56.396036"], ["group_id", 1], ["parent_id", 3360], ["state", "pending"], ["target_id", 2658], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.396036"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.3ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.404202"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.404202"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2659 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2659 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 03:22:56.405389"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2659], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.409115"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2659 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:22:56.410870')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2659 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2659 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.414597"], ["group_id", 1], ["state", "pending"], ["target_id", 2659], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.414597"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.418384"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.418384"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2660 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2660 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 03:22:56.419489"], ["group_id", 1], ["state", "pending"], ["target_id", 2660], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.422764"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2660 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:22:56.424840')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2660 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2660 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.428745"], ["group_id", 1], ["state", "pending"], ["target_id", 2660], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.428745"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.4ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.436219"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.436219"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2661 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2661 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.441587"], ["group_id", 1], ["state", "pending"], ["target_id", 2661], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.441587"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2661 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3366) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2661 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3366) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.449817"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.449817"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2662 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2662 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.455569"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2662], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.455569"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2662 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2662 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3367 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.460176"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2662 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2662 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.7ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3367 [["sent_time", "2015-09-28 04:22:56.461323"], ["updated_at", "2015-09-28 04:22:56.464521"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2662 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2662 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.472431"], ["group_id", 1], ["state", "pending"], ["target_id", 2662], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.472431"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2662 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3368) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2662 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3368) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.479551"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.479551"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.484386"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2663], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.484386"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3369 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.488579"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3369 [["sent_time", "2015-09-28 04:22:56.489716"], ["updated_at", "2015-09-28 04:22:56.492049"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.496889"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2663], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.496889"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3370 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.505530"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3370 [["sent_time", "2015-09-28 04:22:56.506730"], ["updated_at", "2015-09-28 04:22:56.509236"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2663 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.513658"], ["group_id", 1], ["state", "pending"], ["target_id", 2663], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.513658"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2663 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3371) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2663 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3371) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.520762"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.520762"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.524951"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2664], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.524951"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3372 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.529048"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3372 [["sent_time", "2015-09-28 04:22:56.530220"], ["updated_at", "2015-09-28 04:22:56.532605"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.536956"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2664], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.536956"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3373 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.540885"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3373 [["sent_time", "2015-09-28 04:22:56.541937"], ["updated_at", "2015-09-28 04:22:56.544219"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.548512"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2664], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.548512"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3374 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.552483"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3374 [["sent_time", "2015-09-28 04:22:56.553560"], ["updated_at", "2015-09-28 04:22:56.556342"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.561232"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2664], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.561232"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.0ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3375 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.567262"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3375 [["sent_time", "2015-09-28 04:22:56.569994"], ["updated_at", "2015-09-28 04:22:56.572998"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.577360"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2664], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.577360"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3376 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.581348"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3376 [["sent_time", "2015-09-28 04:22:56.582392"], ["updated_at", "2015-09-28 04:22:56.584658"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.588780"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2664], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.588780"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3377 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.592654"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3377 [["sent_time", "2015-09-28 04:22:56.593738"], ["updated_at", "2015-09-28 04:22:56.596196"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.600213"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2664], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.600213"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3378 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.604548"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3378 [["sent_time", "2015-09-28 04:22:56.605726"], ["updated_at", "2015-09-28 04:22:56.608209"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.612446"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2664], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.612446"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3379 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.616448"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3379 [["sent_time", "2015-09-28 04:22:56.617495"], ["updated_at", "2015-09-28 04:22:56.619734"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.623890"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2664], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.623890"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3380 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.628117"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (1.2ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.6ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3380 [["sent_time", "2015-09-28 04:22:56.629461"], ["updated_at", "2015-09-28 04:22:56.633828"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.640481"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2664], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.640481"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3381 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.644546"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3381 [["sent_time", "2015-09-28 04:22:56.645671"], ["updated_at", "2015-09-28 04:22:56.648198"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.652572"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2664], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.652572"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3382 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.656480"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3382 [["sent_time", "2015-09-28 04:22:56.657544"], ["updated_at", "2015-09-28 04:22:56.659931"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2664 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.665019"], ["group_id", 1], ["state", "pending"], ["target_id", 2664], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.665019"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2664 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3383) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2664 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3383) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.672736"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.672736"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2665 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2665 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.677018"], ["group_id", 1], ["state", "pending"], ["target_id", 2665], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.677018"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2665 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2665 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2665 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3384)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2665 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2665 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3384 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.687979"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.692703"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.692703"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2666 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2666 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.697327"], ["group_id", 1], ["state", "pending"], ["target_id", 2666], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.697327"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2666 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2666 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2666 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3385)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2666 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2666 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3385 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.715372"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.720607"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.720607"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2667 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2667 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.725716"], ["group_id", 1], ["state", "pending"], ["target_id", 2667], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.725716"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2667 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2667 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2667 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3386)  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2667 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2667 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3386 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.735132"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3386]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.742238"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.742238"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2668 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2668 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.747327"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2668], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.747327"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2668 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2668 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:56.747327"], ["group_id", 1], ["state", "pending"], ["target_id", 2668], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.752579"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2668 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2668 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2668 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3388)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2668 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2668 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3388 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:22:56.763236"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.770425"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.770425"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2669 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2669 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.779856"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2669], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.779856"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2669 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:22:56.783356') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2669 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:22:56.783356') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2669 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2669 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 04:24:56.779856"], ["group_id", 1], ["parent_id", 3389], ["state", "pending"], ["target_id", 2669], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.794730"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3390]]  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.805303"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.805303"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2670 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2670 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.809970"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2670], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.809970"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2670 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2670 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.814582"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2670], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.814582"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2670 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2670 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.822932"], ["group_id", 1], ["state", "pending"], ["target_id", 2670], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.822932"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2670 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2670 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2670 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3393)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.832619"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.832619"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2671 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2671 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.840907"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2671], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.840907"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2671 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2671 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.845474"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2671], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.845474"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2671 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2671 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:22:56.850853"], ["group_id", 1], ["state", "pending"], ["target_id", 2671], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.850853"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2671 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2671 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2671 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3396) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3396]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.860537"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.860537"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2672 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) ROLLBACK  (0.3ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.870165"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.870165"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2673 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2673 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.877686"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.877686"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2674 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.884462"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.884462"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2675 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.888105"], ["state", "pending"], ["target_id", 2675], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.888105"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2675) LIMIT 1 SQL (1.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:22:56.891562"], ["target_id", 2675], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.891562"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2675 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.3ms) BEGIN  (0.6ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.904122"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.904122"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2676 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.909005"], ["state", "pending"], ["target_id", 2676], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.909005"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2676 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.916760"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.916760"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2677 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.921159"], ["state", "pending"], ["target_id", 2677], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.921159"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2677) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:22:56.924062"], ["target_id", 2677], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:22:56.924062"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2677 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2677 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.5ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.932552"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.932552"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2678 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.939033"], ["state", "pending"], ["target_id", 2678], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.939033"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2678 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2678 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.946200"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.946200"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2679 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.949835"], ["state", "pending"], ["target_id", 2679], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.949835"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2679) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.953134"], ["group_id", 1], ["target_id", 2679], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.953134"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2679 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2679 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.960883"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.960883"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2680 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.964828"], ["state", "pending"], ["target_id", 2680], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.964828"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2680) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:22:56.971494"], ["target_id", 2680], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.971494"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2680 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2680 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.979477"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.979477"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2681 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.983236"], ["state", "pending"], ["target_id", 2681], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.983236"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2681 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2681 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3403 [["group_id", 1], ["updated_at", "2015-09-28 04:22:56.987936"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2681 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2681 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:56.995249"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:56.995249"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2682 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:56.999787"], ["state", "pending"], ["target_id", 2682], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:56.999787"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3404]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2682]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2682 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2682 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:57.008393"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:57.008393"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2683 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:57.011645"], ["state", "pending"], ["target_id", 2683], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:57.011645"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2683) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:22:57.014826"], ["target_id", 2683], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:22:57.014826"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3405]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2683]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2683 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2683 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:57.023054"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:57.023054"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2684 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:57.026848"], ["state", "pending"], ["target_id", 2684], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:57.026848"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2684) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:57.030887"], ["group_id", 1], ["target_id", 2684], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:57.030887"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2684 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3406]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2684]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2684 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:57.041807"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:57.041807"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2685 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:57.045296"], ["state", "pending"], ["target_id", 2685], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:57.045296"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2685 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2685 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:57.052878"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:57.052878"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2686 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:57.056254"], ["state", "pending"], ["target_id", 2686], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:57.056254"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2686) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:22:57.059398"], ["target_id", 2686], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:22:57.059398"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2686 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2686 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:57.066364"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:57.066364"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2687 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:57.069789"], ["state", "pending"], ["target_id", 2687], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:57.069789"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2687) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:57.072975"], ["group_id", 1], ["target_id", 2687], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:57.072975"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2687 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2687 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:57.082040"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:57.082040"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2688 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:57.085987"], ["state", "pending"], ["target_id", 2688], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:57.085987"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2688 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'szZEWdYTjBS0PN7YGteyVwQbldJXvFWOYzdGh93ekZfQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:57.089673"], ["target_id", 2688], ["target_type", "User"], ["token", "szZEWdYTjBS0PN7YGteyVwQbldJXvFWOYzdGh93ekZfQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:57.089673"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:57.095257"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:57.095257"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2689 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:57.099205"], ["state", "pending"], ["target_id", 2689], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:57.099205"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2689 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'nWXYna14riZsaaPYoLyOjwMjnUPSc37srkJHsDOb5ucw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:57.103084"], ["target_id", 2689], ["target_type", "User"], ["token", "nWXYna14riZsaaPYoLyOjwMjnUPSc37srkJHsDOb5ucw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:57.103084"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2689 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:22:57.109886"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:22:57.109886"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2690 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:57.113546"], ["state", "pending"], ["target_id", 2690], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:57.113546"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2690 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'wuWpnj1qTh6r6cu_yWID8gmBDA74aJyn-IVOAAeer-Cg' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:57.117792"], ["target_id", 2690], ["target_type", "User"], ["token", "wuWpnj1qTh6r6cu_yWID8gmBDA74aJyn-IVOAAeer-Cg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:57.117792"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 335 [["active", "f"], ["updated_at", "2015-09-28 04:22:57.120379"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2690 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'W-9GmycLg2aXkJlxRREZPQMpkj-vpPqo3nCNwAeOVS_Q' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:22:57.123631"], ["target_id", 2690], ["target_type", "User"], ["token", "W-9GmycLg2aXkJlxRREZPQMpkj-vpPqo3nCNwAeOVS_Q"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:22:57.123631"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:08.674159"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:08.674159"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2691 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:08.706558"], ["state", "pending"], ["target_id", 2691], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:08.706558"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 2691 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:08.715197"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:08.715197"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2692 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:08.718498"], ["state", "pending"], ["target_id", 2692], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:08.718498"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:08.722452"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:08.722452"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2693 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:08.725517"], ["state", "pending"], ["target_id", 2693], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:08.725517"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:08.729553"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:08.729553"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2694 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:08.732733"], ["state", "pending"], ["target_id", 2694], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:08.732733"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2694 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3416 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:24:08.735605"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:08.744633"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:08.744633"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2695 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:08.747957"], ["state", "pending"], ["target_id", 2695], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:08.747957"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2695 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3417 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:24:08.751688"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:08.757343"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:08.757343"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2696 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:08.762142"], ["state", "pending"], ["target_id", 2696], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:08.762142"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2696 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3418 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:24:08.765856"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:08.771060"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:08.771060"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2697 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:08.775045"], ["state", "pending"], ["target_id", 2697], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:08.775045"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2697 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3419 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:24:08.778072"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:08.783330"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:08.783330"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2698 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:08.787951"], ["state", "pending"], ["target_id", 2698], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:08.787951"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2698 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3420]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:08.798740"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:08.798740"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2699 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:08.803095"], ["state", "pending"], ["target_id", 2699], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:08.803095"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2699 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2699 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3421 [["state", "sent"], ["updated_at", "2015-09-28 04:24:08.810114"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2699 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3421 [["sent_time", "2015-09-28 04:24:08.811312"], ["updated_at", "2015-09-28 04:24:08.812691"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3421]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:08.817686"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:08.817686"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2700 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:08.821058"], ["state", "pending"], ["target_id", 2700], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:08.821058"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2700 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:08.823304') NewPostNotification Load (0.7ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2700 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:08.823304') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2700 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3422]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:08.832632"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:08.832632"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2701 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:08.835954"], ["state", "pending"], ["target_id", 2701], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:08.835954"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2701 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2701 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:08.840530') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2701 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:08.840530') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2701 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3423]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:08.848842"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:08.848842"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2702 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:08.852191"], ["state", "pending"], ["target_id", 2702], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:08.852191"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2702 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2702 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:08.857088') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2702 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:08.857088') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2702 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3424]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:08.866049"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:08.866049"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:08.869538"], ["state", "pending"], ["target_id", 2703], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:08.869538"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2703 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 3425)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3425 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:08.875887"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3425]] User Load (0.5ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2703]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2703 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2703]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3425 [["sent_time", "2015-09-28 04:24:08.886421"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:08.889382"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3425]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2703]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2703 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.4ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (3.7ms) NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2703 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'L8tsJJBNxd2mTuHFWXYMJQC-kNTa6X8abQGIa-OUJ8lg' LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:08.937548"], ["target_id", 2703], ["target_type", "User"], ["token", "L8tsJJBNxd2mTuHFWXYMJQC-kNTa6X8abQGIa-OUJ8lg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:08.937548"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 206.7ms Sent mail to user@example.com (8.5ms) Date: Mon, 28 Sep 2015 14:24:09 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c0e91b85a_139b23fe5cd8601f8438cb@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.119047"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.119047"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2704 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.122385"], ["state", "pending_as_aggregation_parent"], ["target_id", 2704], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.122385"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2704 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.125607"], ["state", "pending"], ["target_id", 2704], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.125607"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2704 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2704 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 3427)  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.135884"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.135884"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2705 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.7ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.139630"], ["state", "pending"], ["target_id", 2705], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.139630"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2705 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2705 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3428 [["state", "sent"], ["updated_at", "2015-09-28 04:24:09.146057"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2705 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3428 [["sent_time", "2015-09-28 04:24:09.147190"], ["updated_at", "2015-09-28 04:24:09.148595"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3428]] User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2705]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2705 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2705 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.1ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.5ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2705 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'gSCgGr-Oih7okFJJPEyt7AnDaGCx4b0uWollPEKBcFEw' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.159395"], ["target_id", 2705], ["target_type", "User"], ["token", "gSCgGr-Oih7okFJJPEyt7AnDaGCx4b0uWollPEKBcFEw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.159395"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.6ms Sent mail to user@example.com (1.7ms) Date: Mon, 28 Sep 2015 14:24:09 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c0e927be2_139b23fe5cd8601f843915@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.166781"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.166781"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2706 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.170330"], ["state", "pending"], ["target_id", 2706], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.170330"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2706 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3429 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 04:24:09.173424"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.177801"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.177801"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2707 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.180893"], ["state", "pending"], ["target_id", 2707], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.180893"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2707) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:24:09.185944"], ["target_id", 2707], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:24:09.185944"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3430]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2707]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2707 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2707 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.194747"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.194747"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2708 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.197983"], ["state", "pending"], ["target_id", 2708], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.197983"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3431]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2708]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2708 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2708 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.207688"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.207688"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2709 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.211729"], ["state", "pending"], ["target_id", 2709], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.211729"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2709 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2709 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3432 [["state", "sent"], ["updated_at", "2015-09-28 04:24:09.216470"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2709 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3432 [["sent_time", "2015-09-28 04:24:09.217804"], ["updated_at", "2015-09-28 04:24:09.219243"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3432]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2709]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2709 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2709 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2709 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'W3pcRMCQi0K1id-cWVx-KwumPivZwuY9ruadaNuVO4Tg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.227801"], ["target_id", 2709], ["target_type", "User"], ["token", "W3pcRMCQi0K1id-cWVx-KwumPivZwuY9ruadaNuVO4Tg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.227801"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.8ms Sent mail to user@example.com (1.7ms) Date: Mon, 28 Sep 2015 14:24:09 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c0e938870_139b23fe5cd8601f844074@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.235351"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.235351"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2710 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.238459"], ["state", "pending"], ["target_id", 2710], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.238459"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.1ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3433]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2710]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2710 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2710 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.247488"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.247488"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2711 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.250939"], ["state", "pending"], ["target_id", 2711], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.250939"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3434]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2711]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2711 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2711]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2711 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3434 [["sent_time", "2015-09-28 04:24:09.255024"], ["state", "sent"], ["updated_at", "2015-09-28 04:24:09.258142"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2711 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.264757"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.264757"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2712 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.267825"], ["state", "pending"], ["target_id", 2712], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.267825"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2712 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.271274"], ["state", "pending"], ["target_id", 2712], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.271274"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3436]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2712]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2712 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2712]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2712 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3436 [["sent_time", "2015-09-28 04:24:09.275571"], ["state", "sent"], ["updated_at", "2015-09-28 04:24:09.278113"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2712]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2712 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3435 [["sent_time", "2015-09-28 04:24:09.279928"], ["state", "sent"], ["updated_at", "2015-09-28 04:24:09.282250"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2712 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2712 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.290287"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.290287"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2713 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.293664"], ["state", "read"], ["target_id", 2713], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.293664"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3437]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2713]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2713 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.301411"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.301411"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.306070"], ["group_id", 2], ["state", "pending"], ["target_id", 2714], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.306070"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3438]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2714]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2714 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2714]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3438 [["sent_time", "2015-09-28 04:24:09.312118"], ["state", "sent"], ["updated_at", "2015-09-28 04:24:09.315485"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3438]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2714]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2714 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2714 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '4IYj7p_NDI9mH-VYkv-jdAQFMXT2Yd38gVa7RkA22YrA' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.328169"], ["target_id", 2714], ["target_type", "User"], ["token", "4IYj7p_NDI9mH-VYkv-jdAQFMXT2Yd38gVa7RkA22YrA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.328169"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.6ms Sent mail to user@example.com (1.7ms) Date: Mon, 28 Sep 2015 14:24:09 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c0e950edf_139b23fe5cd8601f8441bf@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.335440"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.335440"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.339575"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2715], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.339575"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3439 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.344329"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2715 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3439 [["sent_time", "2015-09-28 04:24:09.345578"], ["updated_at", "2015-09-28 04:24:09.347937"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3439]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.354699"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.354699"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2716 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.360589"], ["group_id", 1], ["state", "pending"], ["target_id", 2716], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.360589"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2716 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3440) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.366304"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.366304"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2717 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2717 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.370586"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2717], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.370586"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2717 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2717 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.375115"], ["group_id", 1], ["state", "pending"], ["target_id", 2717], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.375115"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2717 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3442) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.380544"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.380544"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2718 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2718 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.384755"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2718], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.384755"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2718 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2718 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.388885"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2718], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.388885"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2718 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2718 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.394021"], ["group_id", 1], ["state", "pending"], ["target_id", 2718], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.394021"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2718 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3445) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.399480"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.399480"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2719 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2719 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.403479"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 2719], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.403479"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2719 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2719 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.408646"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 2719], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.408646"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2719 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2719 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.412987"], ["group_id", 1], ["state", "pending"], ["target_id", 2719], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.412987"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2719 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3448) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.419050"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.419050"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.423333"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2720], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.423333"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.427760"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2720], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.427760"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2720 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.432259"], ["group_id", 1], ["state", "pending"], ["target_id", 2720], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.432259"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2720 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3451) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.438054"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.438054"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2721 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2721 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 18:24:09.439104"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2721], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.442475"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2721 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:09.444608') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2721 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:09.444608') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2721 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2721 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 04:24:09.449806"], ["group_id", 1], ["parent_id", 3452], ["state", "pending"], ["target_id", 2721], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.449806"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.454196"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.454196"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 03:24:09.455282"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2722], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.459949"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2722 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:09.461791')  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2722 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.465890"], ["group_id", 1], ["state", "pending"], ["target_id", 2722], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.465890"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.469696"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.469696"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 03:24:09.470726"], ["group_id", 1], ["state", "pending"], ["target_id", 2723], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.473950"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2723 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:09.476106')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2723 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.480106"], ["group_id", 1], ["state", "pending"], ["target_id", 2723], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.480106"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.485443"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.485443"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2724 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2724 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.490676"], ["group_id", 1], ["state", "pending"], ["target_id", 2724], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.490676"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2724 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3458) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2724 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3458) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.497774"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.497774"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2725 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2725 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.502373"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2725], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.502373"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2725 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2725 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3459 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.506470"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2725 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2725 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3459 [["sent_time", "2015-09-28 04:24:09.508503"], ["updated_at", "2015-09-28 04:24:09.511016"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2725 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2725 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.515311"], ["group_id", 1], ["state", "pending"], ["target_id", 2725], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.515311"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2725 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3460) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2725 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3460) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.522398"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.522398"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2726 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2726 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.527023"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2726], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.527023"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2726 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2726 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3461 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.531038"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2726 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2726 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3461 [["sent_time", "2015-09-28 04:24:09.532284"], ["updated_at", "2015-09-28 04:24:09.534772"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2726 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2726 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.538963"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2726], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.538963"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2726 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2726 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3462 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.542755"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2726 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2726 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3462 [["sent_time", "2015-09-28 04:24:09.544096"], ["updated_at", "2015-09-28 04:24:09.546725"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2726 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2726 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.551174"], ["group_id", 1], ["state", "pending"], ["target_id", 2726], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.551174"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2726 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3463) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2726 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3463) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.6ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.559412"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.559412"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.563766"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2727], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.563766"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3464 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.567970"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3464 [["sent_time", "2015-09-28 04:24:09.569232"], ["updated_at", "2015-09-28 04:24:09.571633"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.575730"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2727], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.575730"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3465 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.579623"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3465 [["sent_time", "2015-09-28 04:24:09.580795"], ["updated_at", "2015-09-28 04:24:09.583097"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.587296"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2727], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.587296"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3466 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.591159"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3466 [["sent_time", "2015-09-28 04:24:09.592494"], ["updated_at", "2015-09-28 04:24:09.595001"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.599220"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2727], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.599220"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3467 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.603161"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3467 [["sent_time", "2015-09-28 04:24:09.604257"], ["updated_at", "2015-09-28 04:24:09.606774"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.612225"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2727], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.612225"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3468 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.616224"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3468 [["sent_time", "2015-09-28 04:24:09.617464"], ["updated_at", "2015-09-28 04:24:09.619948"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.624309"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2727], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.624309"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3469 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.628543"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3469 [["sent_time", "2015-09-28 04:24:09.629658"], ["updated_at", "2015-09-28 04:24:09.631958"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.636135"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2727], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.636135"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3470 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.640302"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3470 [["sent_time", "2015-09-28 04:24:09.641639"], ["updated_at", "2015-09-28 04:24:09.644223"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.648774"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2727], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.648774"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3471 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.652965"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3471 [["sent_time", "2015-09-28 04:24:09.654106"], ["updated_at", "2015-09-28 04:24:09.656853"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.663644"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2727], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.663644"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3472 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.668424"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3472 [["sent_time", "2015-09-28 04:24:09.670373"], ["updated_at", "2015-09-28 04:24:09.675095"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.680599"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2727], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.680599"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3473 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.684942"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3473 [["sent_time", "2015-09-28 04:24:09.686161"], ["updated_at", "2015-09-28 04:24:09.688658"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.693616"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2727], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.693616"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3474 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.697659"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3474 [["sent_time", "2015-09-28 04:24:09.698817"], ["updated_at", "2015-09-28 04:24:09.701266"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2727 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.705795"], ["group_id", 1], ["state", "pending"], ["target_id", 2727], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.705795"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2727 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3475) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.9ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2727 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3475) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.8ms) ROLLBACK  (0.6ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.719646"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.719646"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2728 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2728 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.724405"], ["group_id", 1], ["state", "pending"], ["target_id", 2728], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.724405"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2728 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2728 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2728 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3476)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2728 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2728 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3476 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.735158"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.739596"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.739596"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2729 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2729 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.744136"], ["group_id", 1], ["state", "pending"], ["target_id", 2729], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.744136"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2729 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2729 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2729 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3477)  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2729 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2729 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3477 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.757831"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.763006"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.763006"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2730 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2730 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.768002"], ["group_id", 1], ["state", "pending"], ["target_id", 2730], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.768002"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2730 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2730 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2730 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3478)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2730 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2730 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3478 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.776880"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3478]]  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.783682"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.783682"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2731 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2731 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.788509"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2731], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.788509"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2731 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2731 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:26:09.788509"], ["group_id", 1], ["state", "pending"], ["target_id", 2731], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.793421"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2731 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2731 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2731 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3480)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2731 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2731 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3480 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:09.803057"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.809296"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.809296"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2732 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2732 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.814228"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2732], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.814228"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2732 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:09.816675') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2732 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:09.816675') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2732 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2732 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 04:26:09.814228"], ["group_id", 1], ["parent_id", 3481], ["state", "pending"], ["target_id", 2732], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.822239"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3482]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.828066"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.828066"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2733 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2733 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.832401"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2733], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.832401"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2733 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2733 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.836739"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2733], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.836739"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2733 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2733 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.840890"], ["group_id", 1], ["state", "pending"], ["target_id", 2733], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.840890"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2733 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2733 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2733 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3485)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.849717"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.849717"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2734 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2734 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.854464"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2734], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.854464"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2734 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2734 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.859780"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2734], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.859780"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2734 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2734 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:09.864263"], ["group_id", 1], ["state", "pending"], ["target_id", 2734], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.864263"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2734 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2734 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2734 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3488) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3488]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.873435"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.873435"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2735 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.879395"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.879395"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2736 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2736 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.886361"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.886361"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2737 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.892466"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.892466"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2738 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.896786"], ["state", "pending"], ["target_id", 2738], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.896786"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2738) LIMIT 1 SQL (0.4ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:24:09.900290"], ["target_id", 2738], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.900290"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2738 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (1.1ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.905734"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.905734"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2739 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.910554"], ["state", "pending"], ["target_id", 2739], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.910554"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2739 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.916126"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.916126"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2740 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.919864"], ["state", "pending"], ["target_id", 2740], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.919864"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2740) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:24:09.923103"], ["target_id", 2740], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:24:09.923103"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2740 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2740 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.929629"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.929629"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2741 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.932925"], ["state", "pending"], ["target_id", 2741], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.932925"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2741 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2741 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.939655"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.939655"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2742 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.943173"], ["state", "pending"], ["target_id", 2742], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.943173"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2742) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.946284"], ["group_id", 1], ["target_id", 2742], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.946284"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2742 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2742 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.953859"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.953859"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2743 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.957912"], ["state", "pending"], ["target_id", 2743], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.957912"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2743) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:24:09.961501"], ["target_id", 2743], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.961501"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2743 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2743 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.969051"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.969051"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2744 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.972415"], ["state", "pending"], ["target_id", 2744], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.972415"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2744 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2744 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3495 [["group_id", 1], ["updated_at", "2015-09-28 04:24:09.976653"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (1.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2744 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2744 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.986069"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.986069"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2745 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:09.989697"], ["state", "pending"], ["target_id", 2745], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:09.989697"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3496]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2745]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2745 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2745 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:09.998710"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:09.998710"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2746 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:10.001968"], ["state", "pending"], ["target_id", 2746], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:10.001968"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2746) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:24:10.005008"], ["target_id", 2746], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:24:10.005008"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3497]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2746]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2746 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2746 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:10.014298"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:10.014298"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2747 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:10.018003"], ["state", "pending"], ["target_id", 2747], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:10.018003"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2747) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:10.021168"], ["group_id", 1], ["target_id", 2747], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:10.021168"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2747 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3498]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2747]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2747 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:10.030572"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:10.030572"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2748 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:10.033888"], ["state", "pending"], ["target_id", 2748], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:10.033888"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2748 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2748 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:10.040954"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:10.040954"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2749 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:10.045219"], ["state", "pending"], ["target_id", 2749], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:10.045219"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2749) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:24:10.048966"], ["target_id", 2749], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:24:10.048966"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2749 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2749 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:10.055745"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:10.055745"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2750 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:10.060354"], ["state", "pending"], ["target_id", 2750], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:10.060354"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2750) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:10.063387"], ["group_id", 1], ["target_id", 2750], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:10.063387"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2750 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2750 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:10.070927"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:10.070927"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2751 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:10.075241"], ["state", "pending"], ["target_id", 2751], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:10.075241"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2751 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'uQu4J0oF8KqvHce-ajSFZAuTtXi4XzpEVxSU_JrU4UJA' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:10.079086"], ["target_id", 2751], ["target_type", "User"], ["token", "uQu4J0oF8KqvHce-ajSFZAuTtXi4XzpEVxSU_JrU4UJA"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:10.079086"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:10.084764"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:10.084764"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2752 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:10.088750"], ["state", "pending"], ["target_id", 2752], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:10.088750"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2752 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.5ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'H3XmSUugftqAoSmGulUuMgUMuxkMtQBRqX-RrfwpxyhQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:10.092343"], ["target_id", 2752], ["target_type", "User"], ["token", "H3XmSUugftqAoSmGulUuMgUMuxkMtQBRqX-RrfwpxyhQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:10.092343"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2752 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:10.099251"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:10.099251"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2753 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:10.102910"], ["state", "pending"], ["target_id", 2753], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:10.102910"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2753 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.4ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 's-h78XPvhsU7PZuqcbNv5AMDBItmCK9UInRsJkkkVH0A' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:10.106498"], ["target_id", 2753], ["target_type", "User"], ["token", "s-h78XPvhsU7PZuqcbNv5AMDBItmCK9UInRsJkkkVH0A"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:10.106498"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 343 [["active", "f"], ["updated_at", "2015-09-28 04:24:10.110663"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2753 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'JdnPiauPoXXZiRYErqaLrgyAsPbfgPFzjoH7Bm5pNVbw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:10.114648"], ["target_id", 2753], ["target_type", "User"], ["token", "JdnPiauPoXXZiRYErqaLrgyAsPbfgPFzjoH7Bm5pNVbw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:10.114648"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:31.821158"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:31.821158"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.7ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2754 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:31.854257"], ["state", "pending"], ["target_id", 2754], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:31.854257"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."target_id" = 2754 AND "notify_user_notifications"."target_type" = 'User' AND (parent_id IS NULL) AND (state IN ('sent_as_aggregation_parent','sent','pending'))  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:31.862528"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:31.862528"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2755 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:31.865975"], ["state", "pending"], ["target_id", 2755], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:31.865975"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:31.870097"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:31.870097"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2756 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:31.873513"], ["state", "pending"], ["target_id", 2756], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:31.873513"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:31.877830"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:31.877830"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2757 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:31.881052"], ["state", "pending"], ["target_id", 2757], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:31.881052"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2757 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3508 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:24:31.884117"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:31.893045"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:31.893045"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2758 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:31.896644"], ["state", "pending"], ["target_id", 2758], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:31.896644"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2758 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3509 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:24:31.899867"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:31.905068"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:31.905068"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2759 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:31.908330"], ["state", "pending"], ["target_id", 2759], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:31.908330"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2759 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.4ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3510 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:24:31.911754"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:31.919721"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:31.919721"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2760 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:31.923444"], ["state", "pending"], ["target_id", 2760], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:31.923444"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2760 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "params" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3511 [["params", "{\"listing_id\":1}"], ["updated_at", "2015-09-28 04:24:31.926648"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') ORDER BY "notify_user_notifications"."id" DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:31.931620"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:31.931620"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2761 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:31.936253"], ["state", "pending"], ["target_id", 2761], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:31.936253"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2761 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3512]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:31.943340"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:31.943340"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2762 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:31.946919"], ["state", "pending"], ["target_id", 2762], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:31.946919"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2762 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2762 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3513 [["state", "sent"], ["updated_at", "2015-09-28 04:24:31.952319"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2762 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3513 [["sent_time", "2015-09-28 04:24:31.953578"], ["updated_at", "2015-09-28 04:24:31.955127"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3513]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:31.960353"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:31.960353"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2763 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:31.965612"], ["state", "pending"], ["target_id", 2763], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:31.965612"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2763 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:31.967560') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2763 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:31.967560') ORDER BY created_at DESC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2763 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3514]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:31.975971"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:31.975971"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2764 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:31.979400"], ["state", "pending"], ["target_id", 2764], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:31.979400"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2764 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2764 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:31.983782') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2764 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:31.983782') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2764 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3515]]  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:31.992070"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:31.992070"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2765 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:31.995178"], ["state", "pending"], ["target_id", 2765], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:31.995178"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2765 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2765 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:32.001165') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2765 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" IS NULL AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:32.001165') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2765 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3516]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.009647"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.009647"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2766 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.013663"], ["state", "pending"], ["target_id", 2766], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.013663"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2766 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2766 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 3517)  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2766 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3517 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.020391"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3517]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2766]] NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2766 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2766]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2766 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3517 [["sent_time", "2015-09-28 04:24:32.031678"], ["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.034504"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2766 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3517]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2766]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2766 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2766 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.4ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (3.8ms) NotifyUser::UserHash Load (0.6ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2766 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '6FQlIVBpnn10ws48jK9ofQ855ggAuF6RL-e0VJaiRK2g' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.083906"], ["target_id", 2766], ["target_type", "User"], ["token", "6FQlIVBpnn10ws48jK9ofQ855ggAuF6RL-e0VJaiRK2g"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.083906"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 205.9ms Sent mail to user@example.com (7.8ms) Date: Mon, 28 Sep 2015 14:24:32 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c1003e97b_13ba93fea1d85e20045777@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.262592"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.262592"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2767 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.266112"], ["state", "pending_as_aggregation_parent"], ["target_id", 2767], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.266112"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2767 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.269146"], ["state", "pending"], ["target_id", 2767], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.269146"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2767 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2767 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND (id != 3519)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.276643"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.276643"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2768 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.279985"], ["state", "pending"], ["target_id", 2768], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.279985"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2768 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2768 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3520 [["state", "sent"], ["updated_at", "2015-09-28 04:24:32.284018"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2768 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3520 [["sent_time", "2015-09-28 04:24:32.285299"], ["updated_at", "2015-09-28 04:24:32.286745"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3520]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2768]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2768 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2768 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2768 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'rCS2OKfzvGDljyDqLhwE6gQMiXaSnxWogXYOcShWjQQw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.296007"], ["target_id", 2768], ["target_type", "User"], ["token", "rCS2OKfzvGDljyDqLhwE6gQMiXaSnxWogXYOcShWjQQw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.296007"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 6.0ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 14:24:32 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c1004935d_13ba93fea1d85e20045881@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.303996"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.303996"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2769 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.307303"], ["state", "pending"], ["target_id", 2769], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.307303"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2769 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3521 [["state", "pending_no_aggregation"], ["updated_at", "2015-09-28 04:24:32.310463"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.315639"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.315639"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2770 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.319022"], ["state", "pending"], ["target_id", 2770], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.319022"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2770) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:24:32.324449"], ["target_id", 2770], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:24:32.324449"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3522]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2770]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2770 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2770 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.332874"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.332874"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.336005"], ["state", "pending"], ["target_id", 2771], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.336005"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::BaseNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3523]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2771]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2771 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.344180"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.344180"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.347501"], ["state", "pending"], ["target_id", 2772], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.347501"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3524 [["state", "sent"], ["updated_at", "2015-09-28 04:24:32.352503"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3524 [["sent_time", "2015-09-28 04:24:32.353751"], ["updated_at", "2015-09-28 04:24:32.355188"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3524]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2772]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2772 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.5ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2772 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'hGBvro6dW_4FMCiuycF29ALqcXq5E-L8J9K1z72HxVMg' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.365102"], ["target_id", 2772], ["target_type", "User"], ["token", "hGBvro6dW_4FMCiuycF29ALqcXq5E-L8J9K1z72HxVMg"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.365102"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 7.2ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 14:24:32 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c1005a0e2_13ba93fea1d85e2004591b@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.373629"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.373629"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2773 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.376921"], ["state", "pending"], ["target_id", 2773], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.376921"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3525]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2773]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2773 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2773 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.384694"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.384694"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2774 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.387841"], ["state", "pending"], ["target_id", 2774], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.387841"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3526]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2774]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2774 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.1ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2774]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2774 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3526 [["sent_time", "2015-09-28 04:24:32.392795"], ["state", "sent"], ["updated_at", "2015-09-28 04:24:32.395409"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2774 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.401617"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.401617"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2775 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.404985"], ["state", "pending"], ["target_id", 2775], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.404985"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2775 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.408821"], ["state", "pending"], ["target_id", 2775], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.408821"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3528]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2775]] NewPostNotification Load (0.8ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2775 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2775]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2775 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3528 [["sent_time", "2015-09-28 04:24:32.414471"], ["state", "sent"], ["updated_at", "2015-09-28 04:24:32.416940"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2775]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2775 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3527 [["sent_time", "2015-09-28 04:24:32.418937"], ["state", "sent"], ["updated_at", "2015-09-28 04:24:32.421798"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2775 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2775 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.429894"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.429894"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2776 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.433187"], ["state", "read"], ["target_id", 2776], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.433187"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3529]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2776]] NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2776 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.440293"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.440293"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2777 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2777 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.444777"], ["group_id", 2], ["state", "pending"], ["target_id", 2777], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.444777"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3530]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2777]] NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2777 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" IN ('pending', 'pending_as_aggregation_parent') AND "notify_user_notifications"."group_id" = 2  (0.2ms) SAVEPOINT active_record_1 User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2777]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2777 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2777 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "state" = $2, "updated_at" = $3 WHERE "notify_user_notifications"."id" = 3530 [["sent_time", "2015-09-28 04:24:32.450104"], ["state", "sent"], ["updated_at", "2015-09-28 04:24:32.453857"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2777 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2777 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3530]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2777]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2777 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2777 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 2  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2777 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer' Rendered notify_user/new_post_notification/action_mailer/notification.html.erb (0.0ms) Rendered /Users/anton/workspace/notify_user/app/views/notify_user/action_mailer/notification.html.erb within notify_user/layouts/action_mailer (0.2ms) NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2777 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'HlNBRiOMrkPvSRHkoBBbegpGYbw-elaHoZTc6oxbcVOw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:32.466740"], ["target_id", 2777], ["target_type", "User"], ["token", "HlNBRiOMrkPvSRHkoBBbegpGYbw-elaHoZTc6oxbcVOw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.466740"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::NotificationMailer#notification_email: processed outbound mail in 5.6ms Sent mail to user@example.com (1.8ms) Date: Mon, 28 Sep 2015 14:24:32 +1000 From: please-change-me-at-config-initializers-notify-user@example.com To: user@example.com Message-ID: <5608c10072ce2_13ba93fea1d85e20046025@Antons-MacBook-Pro.local.mail> Subject: New Notification Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Logo
New Post Notification happened.

Unsubscribe

This is the default generated layout. A privacy declaration could g= o here.

=C2=A9 MyCompany Pty Ltd

ABN 123 456 789

=  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.474185"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.474185"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2778 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2778 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.5ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.478903"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2778], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.478903"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2778 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2778 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3531 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.484565"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2778 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2778 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3531 [["sent_time", "2015-09-28 04:24:32.485879"], ["updated_at", "2015-09-28 04:24:32.488940"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3531]]  (0.1ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.495844"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.495844"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2779 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2779 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.500351"], ["group_id", 1], ["state", "pending"], ["target_id", 2779], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.500351"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2779 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3532) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.506329"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.506329"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2780 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2780 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.510596"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2780], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.510596"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2780 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2780 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.515401"], ["group_id", 1], ["state", "pending"], ["target_id", 2780], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.515401"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2780 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3534) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.521186"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.521186"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2781 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2781 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.525534"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2781], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.525534"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2781 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.6ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2781 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.531256"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2781], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.531256"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2781 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2781 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.535940"], ["group_id", 1], ["state", "pending"], ["target_id", 2781], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.535940"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2781 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3537) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.541600"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.541600"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2782 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2782 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 3 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.546121"], ["group_id", 3], ["state", "sent_as_aggregation_parent"], ["target_id", 2782], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.546121"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2782 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2782 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 0 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.550438"], ["group_id", 0], ["state", "sent_as_aggregation_parent"], ["target_id", 2782], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.550438"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2782 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2782 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.554882"], ["group_id", 1], ["state", "pending"], ["target_id", 2782], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.554882"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2782 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3540) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.560666"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.560666"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2783 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2783 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.565316"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2783], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.565316"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2783 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2783 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.570341"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2783], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.570341"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2783 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2783 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.574916"], ["group_id", 1], ["state", "pending"], ["target_id", 2783], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.574916"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2783 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3543) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent')  (0.3ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.581760"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.581760"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2784 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2784 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 18:24:32.582854"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2784], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.586159"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2784 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:32.588251') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2784 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:32.588251') ORDER BY created_at DESC LIMIT 1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2784 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2784 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 04:24:32.593411"], ["group_id", 1], ["parent_id", 3544], ["state", "pending"], ["target_id", 2784], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.593411"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.597646"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.597646"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2785 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2785 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 03:24:32.598782"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2785], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.602169"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2785 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:32.604185')  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2785 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2785 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.608194"], ["group_id", 1], ["state", "pending"], ["target_id", 2785], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.608194"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.611954"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.611954"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2786 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2786 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-27 03:24:32.612999"], ["group_id", 1], ["state", "pending"], ["target_id", 2786], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.616588"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2786 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:32.618824')  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2786 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2786 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.622789"], ["group_id", 1], ["state", "pending"], ["target_id", 2786], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.622789"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.626619"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.626619"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2787 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2787 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.631830"], ["group_id", 1], ["state", "pending"], ["target_id", 2787], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.631830"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2787 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3550) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2787 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3550) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.638716"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.638716"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2788 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2788 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.642986"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2788], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.642986"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2788 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2788 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3551 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.646726"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2788 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2788 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3551 [["sent_time", "2015-09-28 04:24:32.647907"], ["updated_at", "2015-09-28 04:24:32.650305"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2788 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2788 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.654650"], ["group_id", 1], ["state", "pending"], ["target_id", 2788], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.654650"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2788 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3552) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2788 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3552) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.661396"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.661396"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.666112"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2789], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.666112"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3553 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.670626"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3553 [["sent_time", "2015-09-28 04:24:32.671891"], ["updated_at", "2015-09-28 04:24:32.674521"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.679326"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2789], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.679326"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3554 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.684096"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3554 [["sent_time", "2015-09-28 04:24:32.685254"], ["updated_at", "2015-09-28 04:24:32.687929"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2789 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.692214"], ["group_id", 1], ["state", "pending"], ["target_id", 2789], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.692214"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2789 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3555) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2789 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3555) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.699662"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.699662"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.703873"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2790], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.703873"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3556 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.707939"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3556 [["sent_time", "2015-09-28 04:24:32.709056"], ["updated_at", "2015-09-28 04:24:32.711421"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.715749"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2790], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.715749"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3557 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.719762"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3557 [["sent_time", "2015-09-28 04:24:32.720930"], ["updated_at", "2015-09-28 04:24:32.723332"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (2.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.734417"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2790], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.734417"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3558 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.739037"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3558 [["sent_time", "2015-09-28 04:24:32.740191"], ["updated_at", "2015-09-28 04:24:32.742576"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.747681"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2790], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.747681"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3559 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.751600"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3559 [["sent_time", "2015-09-28 04:24:32.752776"], ["updated_at", "2015-09-28 04:24:32.755369"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.759742"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2790], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.759742"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3560 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.763644"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3560 [["sent_time", "2015-09-28 04:24:32.764878"], ["updated_at", "2015-09-28 04:24:32.767505"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.771790"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2790], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.771790"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3561 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.775611"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3561 [["sent_time", "2015-09-28 04:24:32.776779"], ["updated_at", "2015-09-28 04:24:32.779281"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.783538"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2790], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.783538"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3562 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.787585"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3562 [["sent_time", "2015-09-28 04:24:32.788814"], ["updated_at", "2015-09-28 04:24:32.791304"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.795568"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2790], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.795568"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3563 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.799669"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3563 [["sent_time", "2015-09-28 04:24:32.800923"], ["updated_at", "2015-09-28 04:24:32.803650"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.808114"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2790], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.808114"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3564 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.812134"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3564 [["sent_time", "2015-09-28 04:24:32.813185"], ["updated_at", "2015-09-28 04:24:32.815527"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.820627"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2790], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.820627"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3565 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.825143"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3565 [["sent_time", "2015-09-28 04:24:32.826257"], ["updated_at", "2015-09-28 04:24:32.828667"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.833392"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2790], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.833392"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3566 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.837355"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3566 [["sent_time", "2015-09-28 04:24:32.838490"], ["updated_at", "2015-09-28 04:24:32.841024"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2790 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.845194"], ["group_id", 1], ["state", "pending"], ["target_id", 2790], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.845194"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2790 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3567) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.5ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2790 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3567) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.852904"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.852904"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2791 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2791 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.857438"], ["group_id", 1], ["state", "pending"], ["target_id", 2791], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.857438"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2791 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2791 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2791 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3568)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2791 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2791 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3568 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.867823"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.872540"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.872540"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2792 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2792 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.876815"], ["group_id", 1], ["state", "pending"], ["target_id", 2792], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.876815"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2792 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2792 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2792 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3569)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2792 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2792 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3569 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.890339"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.895520"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.895520"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2793 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2793 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.901698"], ["group_id", 1], ["state", "pending"], ["target_id", 2793], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.901698"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2793 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2793 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2793 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3570)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2793 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2793 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3570 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.911096"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3570]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.917978"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.917978"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2794 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2794 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.923089"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2794], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.923089"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2794 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2794 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:26:32.923089"], ["group_id", 1], ["state", "pending"], ["target_id", 2794], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.927758"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2794 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2794 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2794 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3572)  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2794 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2794 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3572 [["state", "pending_as_aggregation_parent"], ["updated_at", "2015-09-28 04:24:32.937227"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.942576"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.942576"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2795 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2795 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.948795"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2795], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.948795"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2795 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:32.951161') NewPostNotification Load (0.4ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2795 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND "notify_user_notifications"."parent_id" IS NULL AND (created_at >= '2015-09-27 04:24:32.951161') ORDER BY created_at DESC LIMIT 1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2795 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2795 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "parent_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["created_at", "2015-09-28 04:26:32.948795"], ["group_id", 1], ["parent_id", 3573], ["state", "pending"], ["target_id", 2795], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.957166"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3574]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.963428"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.963428"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2796 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2796 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.968212"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2796], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.968212"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2796 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2796 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.972760"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2796], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.972760"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2796 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2796 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.976835"], ["group_id", 1], ["state", "pending"], ["target_id", 2796], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.976835"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2796 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2796 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.5ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2796 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3577)  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:32.985723"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:32.985723"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2797 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2797 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.990268"], ["group_id", 1], ["state", "sent_as_aggregation_parent"], ["target_id", 2797], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.990268"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2797 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2797 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.994538"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2797], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.994538"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2797 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2797 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-28 04:24:32.999794"], ["group_id", 1], ["state", "pending"], ["target_id", 2797], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:32.999794"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2797 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2797 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.4ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."type" = 'NewPostNotification' AND "notify_user_notifications"."target_id" = 2797 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."state" = 'pending_as_aggregation_parent' AND "notify_user_notifications"."group_id" = 1 AND (id != 3580) NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3580]]  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.008747"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.008747"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2798 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.014981"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.014981"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2799 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2799 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.021525"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.021525"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2800 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.027344"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.027344"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2801 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.030721"], ["state", "pending"], ["target_id", 2801], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.030721"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.4ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2801) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:24:33.034522"], ["target_id", 2801], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.034522"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2801 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.1ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.039665"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.039665"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2802 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.042879"], ["state", "pending"], ["target_id", 2802], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.042879"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2802 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.049589"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.049589"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2803 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.053603"], ["state", "pending"], ["target_id", 2803], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.053603"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2803) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:24:33.056943"], ["target_id", 2803], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:24:33.056943"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2803 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2803 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.063471"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.063471"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2804 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.067079"], ["state", "pending"], ["target_id", 2804], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.067079"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2804 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2804 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.073735"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.073735"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2805 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.077698"], ["state", "pending"], ["target_id", 2805], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.077698"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2805) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.081117"], ["group_id", 1], ["target_id", 2805], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.081117"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2805 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2805 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.089318"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.089318"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2806 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.092802"], ["state", "pending"], ["target_id", 2806], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.092802"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.8ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2806) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:24:33.096995"], ["target_id", 2806], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.096995"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2806 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2806 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.4ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.104771"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.104771"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2807 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.108641"], ["state", "pending"], ["target_id", 2807], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.108641"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2807 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2807 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "group_id" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3587 [["group_id", 1], ["updated_at", "2015-09-28 04:24:33.113358"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2807 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2807 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.120727"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.120727"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2808 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.124370"], ["state", "pending"], ["target_id", 2808], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.124370"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3588]] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2808]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2808 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2808 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.133339"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.133339"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2809 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.136938"], ["state", "pending"], ["target_id", 2809], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.136938"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2809) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:24:33.139902"], ["target_id", 2809], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:24:33.139902"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NewPostNotification Load (0.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3589]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2809]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2809 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2809 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.3ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.149454"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.149454"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2810 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.153072"], ["state", "pending"], ["target_id", 2810], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.153072"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2810) LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.156162"], ["group_id", 1], ["target_id", 2810], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.156162"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2810 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 NewPostNotification Load (0.3ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."id" = $1 LIMIT 1 [["id", 3590]] User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT 1 [["id", 2810]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2810 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.166165"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.166165"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2811 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.169728"], ["state", "pending"], ["target_id", 2811], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.169728"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2811 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2811 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.177065"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.177065"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2812 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.181092"], ["state", "pending"], ["target_id", 2812], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.181092"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'action_mailer' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2812) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2015-09-28 04:24:33.184830"], ["target_id", 2812], ["target_type", "User"], ["type", "action_mailer"], ["updated_at", "2015-09-28 04:24:33.184830"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2812 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2812 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'action_mailer'  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.191613"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.191613"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2813 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.195052"], ["state", "pending"], ["target_id", 2813], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.195052"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::Unsubscribe Exists (0.3ms) SELECT 1 AS one FROM "notify_user_unsubscribes" WHERE ("notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."target_id" = 2813) LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_unsubscribes" ("created_at", "group_id", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.199218"], ["group_id", 1], ["target_id", 2813], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.199218"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2813 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2813 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.207453"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.207453"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2814 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.211704"], ["state", "pending"], ["target_id", 2814], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.211704"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.5ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2814 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'r5vO1vxSuZm2NbScRo1bGgt2gIcqxMiXJ0WTex7MpguQ' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.215714"], ["target_id", 2814], ["target_type", "User"], ["token", "r5vO1vxSuZm2NbScRo1bGgt2gIcqxMiXJ0WTex7MpguQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.215714"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.222071"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.222071"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2815 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.226045"], ["state", "pending"], ["target_id", 2815], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.226045"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2815 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.3ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'bT4RAAmd-2L48HIuVBkkdAeTFan37DgE16r6TC0OZfGQ' LIMIT 1 SQL (0.2ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.229700"], ["target_id", 2815], ["target_type", "User"], ["token", "bT4RAAmd-2L48HIuVBkkdAeTFan37DgE16r6TC0OZfGQ"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.229700"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2815 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-28 04:24:33.237040"], ["email", "user@example.com"], ["updated_at", "2015-09-28 04:24:33.237040"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2816 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.240463"], ["state", "pending"], ["target_id", 2816], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.240463"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.3ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2816 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.2ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.2ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = 'PjrbO58Okj5Z4a2GmnpPKQDDA-T2_L5YXBhLwwu3Ll3A' LIMIT 1 SQL (0.5ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.244147"], ["target_id", 2816], ["target_type", "User"], ["token", "PjrbO58Okj5Z4a2GmnpPKQDDA-T2_L5YXBhLwwu3Ll3A"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.244147"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) UPDATE "notify_user_user_hashes" SET "active" = $1, "updated_at" = $2 WHERE "notify_user_user_hashes"."id" = 351 [["active", "f"], ["updated_at", "2015-09-28 04:24:33.247709"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 NotifyUser::UserHash Load (0.4ms) SELECT "notify_user_user_hashes".* FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."target_id" = 2816 AND "notify_user_user_hashes"."target_type" = 'User' AND "notify_user_user_hashes"."type" = 'NewPostNotification' AND "notify_user_user_hashes"."active" = 't' ORDER BY "notify_user_user_hashes"."id" ASC LIMIT 1  (0.1ms) SAVEPOINT active_record_1 NotifyUser::UserHash Exists (0.5ms) SELECT 1 AS one FROM "notify_user_user_hashes" WHERE "notify_user_user_hashes"."token" = '96z1Zj5bH2rt25vO06Jq-gcW6RijFZ1IQBSRftyGOoNw' LIMIT 1 SQL (0.3ms) INSERT INTO "notify_user_user_hashes" ("created_at", "target_id", "target_type", "token", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["created_at", "2015-09-28 04:24:33.251298"], ["target_id", 2816], ["target_type", "User"], ["token", "96z1Zj5bH2rt25vO06Jq-gcW6RijFZ1IQBSRftyGOoNw"], ["type", "NewPostNotification"], ["updated_at", "2015-09-28 04:24:33.251298"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN  (0.2ms) SAVEPOINT active_record_1 SQL (28.2ms) INSERT INTO "users" ("created_at", "email", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2015-09-30 00:39:05.117842"], ["email", "user@example.com"], ["updated_at", "2015-09-30 00:39:05.117842"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (23.1ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (4.8ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-30 00:39:05.214615"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2817], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-30 00:39:05.214615"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (1.4ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3597 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-30 00:39:05.224372"]]  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3597 [["sent_time", "2015-09-30 00:39:05.227494"], ["updated_at", "2015-09-30 00:39:05.230272"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-30 00:39:05.235521"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2817], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-30 00:39:05.235521"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3598 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-30 00:39:05.239978"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3598 [["sent_time", "2015-09-30 00:39:05.241071"], ["updated_at", "2015-09-30 00:39:05.243529"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-30 00:39:05.247892"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2817], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-30 00:39:05.247892"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3599 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-30 00:39:05.251839"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3599 [["sent_time", "2015-09-30 00:39:05.253020"], ["updated_at", "2015-09-30 00:39:05.255589"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-30 00:39:05.260048"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2817], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-30 00:39:05.260048"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3600 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-30 00:39:05.264672"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3600 [["sent_time", "2015-09-30 00:39:05.265800"], ["updated_at", "2015-09-30 00:39:05.268387"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-30 00:39:05.272806"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2817], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-30 00:39:05.272806"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3601 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-30 00:39:05.276691"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3601 [["sent_time", "2015-09-30 00:39:05.277779"], ["updated_at", "2015-09-30 00:39:05.280203"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-30 00:39:05.285191"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2817], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-30 00:39:05.285191"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3602 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-30 00:39:05.289717"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3602 [["sent_time", "2015-09-30 00:39:05.290913"], ["updated_at", "2015-09-30 00:39:05.293391"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-30 00:39:05.297990"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2817], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-30 00:39:05.297990"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3603 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-30 00:39:05.302120"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3603 [["sent_time", "2015-09-30 00:39:05.303230"], ["updated_at", "2015-09-30 00:39:05.305529"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-30 00:39:05.309747"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2817], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-30 00:39:05.309747"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3604 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-30 00:39:05.314006"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.4ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3604 [["sent_time", "2015-09-30 00:39:05.315290"], ["updated_at", "2015-09-30 00:39:05.317657"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-30 00:39:05.322650"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2817], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-30 00:39:05.322650"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3605 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-30 00:39:05.326602"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3605 [["sent_time", "2015-09-30 00:39:05.327739"], ["updated_at", "2015-09-30 00:39:05.330213"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-30 00:39:05.335002"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2817], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-30 00:39:05.335002"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3606 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-30 00:39:05.340681"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.4ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3606 [["sent_time", "2015-09-30 00:39:05.342036"], ["updated_at", "2015-09-30 00:39:05.344745"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-30 00:39:05.349230"], ["group_id", 1], ["state", "pending_as_aggregation_parent"], ["target_id", 2817], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-30 00:39:05.349230"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) UPDATE "notify_user_notifications" SET "state" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3607 [["state", "sent_as_aggregation_parent"], ["updated_at", "2015-09-30 00:39:05.353177"]]  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.3ms) UPDATE "notify_user_notifications" SET "sent_time" = $1, "updated_at" = $2 WHERE "notify_user_notifications"."id" = 3607 [["sent_time", "2015-09-30 00:39:05.354328"], ["updated_at", "2015-09-30 00:39:05.356709"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1  (0.5ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification'  (0.3ms) SELECT COUNT(*) FROM "notify_user_unsubscribes" WHERE "notify_user_unsubscribes"."target_id" = 2817 AND "notify_user_unsubscribes"."target_type" = 'User' AND "notify_user_unsubscribes"."type" = 'NewPostNotification' AND "notify_user_unsubscribes"."group_id" = 1 SQL (0.2ms) INSERT INTO "notify_user_notifications" ("created_at", "group_id", "state", "target_id", "target_type", "type", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["created_at", "2015-09-30 00:39:14.863533"], ["group_id", 1], ["state", "pending"], ["target_id", 2817], ["target_type", "User"], ["type", "NewPostNotification"], ["updated_at", "2015-09-30 00:39:14.863533"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.8ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2817 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3608) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (2.2ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2817 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3608) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.6ms) SELECT COUNT(*) FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2817 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3608) AND "notify_user_notifications"."state" IN ('sent_as_aggregation_parent', 'pending_as_aggregation_parent') NewPostNotification Load (0.6ms) SELECT "notify_user_notifications".* FROM "notify_user_notifications" WHERE "notify_user_notifications"."type" IN ('NewPostNotification') AND "notify_user_notifications"."target_id" = 2817 AND "notify_user_notifications"."target_type" = 'User' AND "notify_user_notifications"."group_id" = 1 AND (id != 3608) AND "notify_user_notifications"."state" = 'sent_as_aggregation_parent' ORDER BY created_at DESC LIMIT 1  (0.5ms) ROLLBACK